[Enhance]: Relax collection, field, and document ID name validation
- Dominant language
- C++
- Stars
- 15.9k
- Forks
- 998
- Avg merge
- 4d 7h
- Merged PRs (30d)
- 34
Description
### Affected Component
DB
### Current Behavior
The current name validation rules are very restrictive:
```c++
const std::regex COLLECTION_NAME_REGEX("^[a-zA-Z0-9_-]{3,64}$");
const std::regex FIELD_NAME_REGEX("^[a-zA-Z0-9_-]{1,32}$");
const std::regex DOC_PK_REGEX("^[a-zA-Z0-9_!@#$%+=.-]{1,64}$");
```
I don't see enough reasons to have such restrictions.
### Desired Improvement
Lifting or relaxing these restrictions, or making them configurable, for:
- collection names
- field names
- document primary keys / IDs
A more permissive validation rule, or a user-configurable validator, would make Zvec easier to adopt in heterogeneous environments.
A more clear and user-friendly message indicating what is not allowed.
### Impact
- Better compatibility with existing datasets and external identifiers
- Easier migration from other storage systems
- Reduced need for application-side name rewriting or ID normalization
- Less friction when integrating Zvec with multi-language tooling
Contributor guide
Assessment
This issue has not been assessed yet.