Files
rag-technical-docs-assistant/AGENTS.md
T
amirhosein mazaheri ca8833dd2f docs: restructure documentation hierarchy and update agent reference map
- Organize architecture, specifications, plans, and guides into dedicated subdirectories under docs/
- Remove legacy and duplicate documents from data/documents/
- Update AGENTS.md, README.md, and agent skills to target canonical docs paths
2026-10-07 16:19:24 +03:30

2.9 KiB

Repository guidance

Phase 1 development

Use the shared reference map for document authority, current source locations, commands, and unresolved decisions. Read applicable nested instructions before editing.

  • Deliver Phase 1 with a modular FastAPI backend and a separate ingestion worker from the same codebase. The current prototype does not yet implement that target.
  • Each upload creates an independent document; never overwrite its original content in place. Do not introduce document_versions, version_id, or version_no for document content.
  • Chunks and ingestion jobs reference document_id; answer sources reference document_id and chunk_id. Retry processes the same eligible failed document and job.
  • Only authorized, ready, active, undeleted documents are searchable. Backend-derived identity and scope cannot be overridden by model arguments.
  • Text and Live use the same backend search implementation. Keep persistent provider secrets server-side and provider-specific objects behind adapters.
  • Follow the documented request deduplication, worker claim/lease fencing, atomic publication, and context invalidation rules for affected workflows.
  • Preserve configuration revisions, knowledge selection revisions, access epochs, and embedding profile metadata; these are not document-content versioning.
  • Keep API/schema documentation and consumers aligned with intentional contract changes. Never change a contract merely to excuse a bug.
  • Avoid unnecessary dependencies, services, abstractions, and unrelated refactoring. Preserve unrelated working-tree changes.

The Phase 1 plan governs scope, API/database documents govern their contracts, and the implementation guide governs workflows. Broader architecture is context, not authorization for deferred features. Existing code is evidence, not proof that conflicting behavior is correct. Surface material contradictions; isolate missing product decisions and continue independent work.

Skills and checks

Repository skills live in .agents/skills/: implement-feature, write-tests, and review-change. Implementation includes necessary validation; tests-only work reports product defects without silently fixing them; review is read-only unless fixes are requested. Do not recursively dispatch between skills.

Verified inspection commands from the repository root: git status --short, git diff --check, and rg --files --hidden -g '!.git/**'. The dependency manifest is pyproject.toml; provider-free checks use .venv/Scripts/python -m pytest -m "not postgres". PostgreSQL acceptance uses .venv/Scripts/python -m pytest -m postgres --require-postgres with an isolated TEST_DATABASE_URL. Missing configuration must fail acceptance; ordinary-suite skips do not prove database behavior. No build/lint pipeline exists. See the reference map and docs/guides/ingestion-foundation-setup.md for setup and actual results. Treat applied revisions as immutable.