-
Notifications
You must be signed in to change notification settings - Fork 166
Open
Labels
enhancementNew feature or requestNew feature or request
Description
Summary
Indexing markdown section headers (## Heading) in the parser would unlock two capabilities from a single change:
- Section validation — schemas could declare required sections and validate that observations appear in the correct section
- Deep-linking — permalinks could point to sections within documents (e.g.,
memory://note#section)
Current State
- The parser is completely section-agnostic — observations and relations are extracted by pattern matching regardless of which
##section they appear under - The validator receives flat
(category, content)tuples with no section context - Section headers like
## Observations,## Relations,## Backgroundare purely organizational/visual
Proposed Changes
Parser
- Track which section each observation/relation was extracted from
- Index section headers as searchable/queryable metadata
- Preserve section context through the parse → validate pipeline
Schema Format Extension
The picoschema format could extend with a sections key:
schema:
name: string
role?: string
sections:
- Background
- Methods
- FindingsDeep-linking
With headers indexed, permalinks could reference specific sections:
memory://coffee-brewing-methods#methodsmemory://auth-service#observations
Context
- Schema system core (parser, resolver, validator, inference, diff) has 100+ tests at high coverage
- Schema router integration tests completed (8 tests in
tests/api/v2/test_schema_router.py) - Router
search_fnbug was fixed during test work — was returning search index metadata instead of fullentity_metadata
🤖 Generated with Claude Code
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request