Skip to content

bug(llc/kb): ChromaDB 1.x rejects ':' in collection names → company creation 500 (InvalidArgumentError) #10743

Description

@mrveiss

After the KB client fix (#10737), company creation now reaches ChromaDB but 500s:

chromadb.errors.InvalidArgumentError: Validation error: name: Expected a name containing 3-512 characters from [a-zA-Z0-9._-]... Got: company:<uuid>

The LLC KB layer names collections company:<uuid>, company:<uuid>:agents, agent:<id>, etc. (collections.py, capability_indexer.py, ac_suggester.py, artifact_ingestor.py, work_item_kb.py, work_product_service.py). ChromaDB 1.x forbids the colon. The colon is also a logical separator parsed via .split(":") (companies.py, inheritance.py) and used for Redis channels (publisher.py) — so changing the convention at the source touches ~8 files + fragile parsers.

Fix: sanitize names to ChromaDBs charset ([a-zA-Z0-9._-], colon→underscore) at the async ChromaDB adapter boundary (knowledge/backends/async_chromadb_adapter.py). Applied on create+read consistently; no-op for colon-free KB names; LLC logical names/parsers untouched.

Follow-up: consider consolidating the duplicated inline collection-name builders through KbCollectionManager.collection_name().

Activity

  1. github-actions commented on Jun 30, 2026

    @github-actions
    Contributor

    PR #10745 (merged to Dev_new_gui) references this issue with a close keyword.

    fix(kb): sanitize ChromaDB collection names to allowed charset (fixes company-create 500) (#10743)

    If this issue is fully resolved, close it manually. If work remains, no action is needed.

  2. mrveiss commented on Jul 1, 2026

    @mrveiss
    OwnerAuthor

    Closed — fix already merged to Dev_new_gui (merged-but-not-closed). Commit: b4bfe639a. Verified in current tree: async_chromadb_adapter.py:35 _chroma_safe_name() sanitizes collection names, applied on get/create/delete. Discoveries: none.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions