CoolFace
Apppublic

MitrAnlil/2547-Mevzuat-AI

sourceHugging Faceapache-2.0updated 3mo agoView on Hugging Face
0likes
App README

MitrAnlil 2547 MVP Pre-Release

MitrAnlil 2547, 2547 sayılı Yükseköğretim Kanunu için kaynak gösterimli normatif bilgi asistanıdır. Bu klasör MVP öncesi temiz deploy paketidir; eski deneme paketleri, zip arşivleri ve legacy RAG dosyaları bu paketin parçası değildir.

Runtime Architecture

Runtime tek dondurulmuş MCKF bilgi kaynağını yükler:

text
data/mckf/2547_mckf_ontology.json

Bu paket runtime sırasında legacy chunk, semantic-unit, canonical-concept veya demo-critical-concept dosyalarına ihtiyaç duymaz.

Ana akış:

text
data/source/2547_clean.txt
-> structural parser
-> articles / clauses / evidence spans
-> MCKF ontology
-> semantic role retrieval
-> LLM synthesis or deterministic fallback
-> full article sources
-> feedback logging
-> feedback-to-regression candidates

MVP Pre-Release Changes

  • —Clean canonical package: mitranlil_2547_mvp_pre_release.
  • —Golden checks expanded from 8 to 52 cases.
  • —Explicit article references such as Madde 53/B and Ek Madde 12 are treated as retrieval filters.
  • —More specific actor detection for board/council-style entities.
  • —Concept-title matching now helps distinguish close provisions such as Madde 6 vs Madde 7.
  • —Legacy source-highlight helpers were removed from runtime source rendering.
  • —Ambiguous short follow-up prompts such as görevleri now ask for clarification instead of forcing retrieval.
  • —Default answer selection is scoped to the best article to avoid mixing unrelated sources.
  • —Source panels render as bounded scrollable source boxes instead of oversized/collapsing details blocks.
  • —Feedback records now mark low-score/problem categories as regression-review candidates.
  • —tools/export_feedback_regression_candidates.py exports review candidates to data/feedback/regression_candidates.jsonl.

Hugging Face Space Settings

Variables:

text
LLM_PROVIDER=groq
GROQ_MODEL=llama-3.3-70b-versatile
MAX_NEW_TOKENS=1000
MAX_CONTEXT_CHARS=3000
CHATBOT_HEIGHT=820
EVAL_CONTEXT_MAX_CHARS=6000

Secret:

text
GROQ_API_KEY=...

GROQ_API_KEY must exist only as a Hugging Face Secret, not also as a public Variable.

Verification

Run from this package root:

bash
python -m compileall .
python tools/build_mckf_from_source.py
python tools/audit_mckf.py
python tools/run_golden_checks.py
python tools/runtime_health_check.py
python tools/export_feedback_regression_candidates.py

Current verified result:

text
MCKF outputs rebuilt from data/source/2547_clean.txt
articles=207 clauses=819 evidence_spans=2086
MCKF v0.7 audit passed
Golden checks: 52/52 passed
MCKF v0.7 runtime health check passed
Sequential source-stability checks passed
llm_provider=groq
llm_available=False in local verification without GROQ_API_KEY

Known MVP Limits

  • —Local verification does not execute external Groq synthesis because GROQ_API_KEY is stored as a Hugging Face Secret.
  • —The semantic role extractor is still heuristic.
  • —Some broad natural-language queries remain follow-up candidates for the next regression cycle, especially where several provisions share similar wording.
  • —The system is a source-grounded explanation assistant, not legal advice.