How jainmokshit1-byte/specid works
SpecID is a prototype for governing a shared national material registry: it aims to turn CPSE ERP records into canonical specifications, compare them with explicit verdicts, and issue CNMCs with legacy-code crosswalks. The documented material workflow is present alongside an API and a currently small set of implemented web screens; the route table describes broader registry, review, evaluation, and rulebook screens, many of which render placeholders. The CLI references the decision-engine modules, but the sampled excerpts do not establish a complete runtime material-ingestion pipeline. The graph shows documented stages and evidenced application wiring without claiming that unsampled capabilities are implemented.
Main entry points: decide.py Verdict decision · main.py API application · extract.py Attribute extraction · client.ts API client
Components 22
Web application
- Web routing
frontend/src/App.tsx - Product screens
frontend/src/pages - API client
frontend/src/api/client.ts - Web session
frontend/src/auth/session.ts
API and identity
- API application
backend/app/main.py - Login routes
backend/app/api/auth.py - User services
backend/app/services/users.py - Token security
backend/app/security/auth.py - Audit routes
backend/app/api/audit.py - Audit service
backend/app/services/audit.py
Specification engine
- Verdict decision
backend/app/core/decide.py - Attribute extraction
backend/app/core/extract.py - Specification normalisation
backend/app/core/normalise.py - Category rule templates
backend/app/core/templates.py - Unit conversion
backend/app/core/units.py - Specification and evidence types
backend/app/core/types.py - Engine CLI
backend/app/cli.py
Persistence and evaluation
- Synthetic evaluation data
backend/app/eval/generator.py - Application database
backend/app/db/models.py - Database sessions
backend/app/db/session.py - CNMC registry and crosswalk
backend/app/db
Other components
- CPSE ERP user
Connections 25
- CPSE ERP user → Web routing: uses
README.md - Web routing → Product screens: routes to
frontend/src/App.tsx - Product screens → API client: requests data
frontend/src/pages/Users.tsx - API client → Web session: reads token
frontend/src/api/client.ts - API client → API application: sends API requests
README.md - API application → Login routes: registers router
backend/app/main.py - API application → Audit routes: registers router
backend/app/main.py - Login routes → User services: delegates login
backend/app/api/auth.py - User services → Token security: creates tokens
backend/app/services/users.py - Login routes → Database sessions: gets session
backend/app/api/auth.py - User services → Application database: reads and updates users
backend/app/services/users.py - Audit routes → Audit service: uses audit service
backend/app/api/audit.py - Audit service → Application database: records events
backend/app/services/audit.py - API application → Category rule templates: loads templates
backend/app/main.py - CPSE ERP user → Attribute extraction: provides ERP records
README.md - Attribute extraction → Specification normalisation: canonicalises attributes
backend/app/core/extract.py - Attribute extraction → Unit conversion: uses unit rules
backend/app/core/extract.py - Specification normalisation → Verdict decision: prepares specifications
README.md - Verdict decision → Category rule templates: applies rules
backend/app/core/decide.py - Verdict decision → Specification and evidence types: returns verdict and evidence
backend/app/core/decide.py - Engine CLI → Verdict decision: references engine
backend/app/cli.py - Engine CLI → Attribute extraction: references engine
backend/app/cli.py - Verdict decision → CNMC registry and crosswalk: issues CNMC
README.md - CNMC registry and crosswalk → Application database: stores registry records
- Synthetic evaluation data → Unit conversion: uses unit rules
backend/app/eval/generator.py