Commit History
-
[NOTICKET] fix(planner): reject analyze_* fed from metadata/documents tools
The planner sometimes wired an analyze_* tool's 'data' to check_data (catalog metadata) instead of retrieve_data (rows); the plan passed structural validation but analyze_* then failed to find its columns at runtime (silent ColumnNotFoundError). Add PlannerValidator Check 9: an analyze_* 'data' placeholder must not reference a catalog.introspection (check_data/check_knowledge) or retrieval.documents (retrieve_knowledge) task — a category denylist, so retrieve_data and table-producing analyze_* chains stay valid. Reinforce with prompt guidance (planner.md: never feed analyze_* from check_data) + a new analyze_descriptive few-shot (Example F). Also log a compact plan dump on 'analysis planned' for diagnosability.958c76f -
[NOTICKET] fix(agents): analysis answer reply-language + number formatting
The Assembler (analysis answer composer) had no reply-language rule and drifted to English; it also detected language from the router's rewritten_query (normalized to English) rather than the user's turn. Detect reply_language from the ORIGINAL message in chat_handler and thread it through coordinator -> assembler; add the [Reply language] default+explicit-override rule to assembler.md. Also add number formatting to assembler.md: round to a sensible default precision (honoring an explicit user request like '2 angka di belakang koma'), match prose and table cells, and use the decimal separator of the reply language (comma for Indonesian).5a010a6 -
[NOTICKET] fix(agents): soften injected reply-language line to a default, not ONLY
The [Reply language] value was injected as 'Respond ONLY in: X', which fought the system prompt's 'default + explicit-request exception' rule and could make the model ignore an explicit 'jawab dalam bahasa Inggris'. Inject just the detected value; the rule (and the override exception) lives in chatbot_system.md.ca3f670 -
[NOTICKET] fix(agents): lock analysis answer language to the user's turn
The analysis answer composer (ChatbotAgent / chatbot_system.md) had no reply-language rule, so it drifted to English even for Indonesian questions (the data context — column names, rows — is English). Extract the deterministic detector from help.py into a shared src/agents/language.py, enrich the Indonesian markers with common chat abbreviations (brp, gmn, yg, ...), and add a history fallback so a short/ambiguous turn inherits the conversation language instead of the team default. ChatbotAgent now computes the language per turn and injects a [Reply language] hard directive; chatbot_system.md gained the matching hard rule (mirrors help.md). help.py re-exports the moved names, so its call sites + tests are unchanged.3e1772d -
feat(guardrails): add input guard, out_of_scope intent, and refusal handling
Rifqi Hafizuddin +1: Claude Fable 5Layered jailbreak/prompt-injection defense wired into ChatHandler.handle (covers the live v2 chat path). Closes the gap where the only defense was soft prompt text on one agent plus Azure's inconsistent content filter. - Input guard (src/agents/guard.py + prompts/input_guard.md): a cheap GPT-4o classifier screening injection/secrets/abuse BEFORE the router. Fail-open on guard error, fail-closed on detection; Azure content-filter trip = block. Swappable seam (local classifier now, Prompt Shields later). - out_of_scope router intent: deterministic canned refusal for off-topic / manipulation, no downstream LLM. Fixes the old no-refuse contradiction. - Content-filter error handling: clean refusal instead of leaking the raw Azure 400 blob. - Language-matched refusals (EN/ID), strict-refuse policy (src/agents/refusals.py). - Prompt hardening: instruction-hierarchy rule in guardrails.md. - Rate limit (30/min) on the v2 chat endpoint. - Eval regression cases (out_of_scope_*) in the …0bbc27b
-
fix(planner): harden plan validation to reduce retry thrash on structured questions
Rifqi Hafizuddin +1: Claude Opus 4.8- render_registry now shows each tool's full ALLOWED args (not just required), so the LLM stops inventing args like order_by/limit on analyze_aggregate. - planner.md: document QueryIR filter value_type rules (it's the element type, never "list", copied verbatim from the catalog [data_type]) and steer "top N by <metric>" to the grouped-totals plan (no in-query ranking yet). - add a non-date filter few-shot (in-list string + numeric decimal). - accumulate the full validation-error history across retries so an attempt fixes ALL prior errors instead of reintroducing an earlier one (value_type -> arg -> value_type whack-a-mole). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>1619dd3 -
/fix report: group findings by analysis, dedup, code-span-safe MDX escaping
Rifqi Hafizuddin +1: Claude Opus 4.8- Key Findings now grouped under each analysis's restated question so results from different questions don't read as one contradictory list - dedup exact-duplicate findings within a record - _mdx_escape leaves inline code spans verbatim (`product_id` no longer renders as `product\_id`) Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>029b488 -
[NOTICKET] fix(planner): repair near-miss catalog ids in QueryIR before validation
The planner LLM occasionally drops, inserts, or mutates a single character when copying an opaque catalog id (e.g. c_b7489c7a4b5 instead of c_b7489c7a4b5f). The IRValidator then rejects the IR on an exact-match lookup, the planner retries with the same typo, and the analysis aborts after N attempts ("planner failed validation after 3 attempts"). Add IRRepairer (src/query/ir/repair.py): before validation, rewrite an unresolvable id to the unique catalog id within edit-distance 1, covering dropped/inserted/substituted chars. When zero or 2+ candidates match, the id is left untouched so the validator still fails loudly -- it never guesses. Because catalog ids are fixed-length hashes, ambiguity is astronomically unlikely, and the unique-or-refuse rule is the guarantee. Wired before validate at all three IR entry points: the planner validator (writes the repaired IR back into the tool call so the executor runs the fixed IR, not just the validator), QueryService, and the retrieve_data tool…aacd4d1 -
/fix report: remove record_id hash citations, EDA (for future tool) change to data source, transform to mdx-safe
Rifqi Hafizuddinb1b1017 -
/fix analysis + report_inputs and storage update (#9)
- fix(chat): drop ENABLE_SLOW_PATH flag + make chat persistence read-only (b8b76c4fb8db21de183cc6f80c0acba0d35bdad1) - [NOTICKET] feat(storage): read tabular Parquet from Supabase S3 via provider toggle (3f48226adaf2ed107a4eb2c0373cbb73fc62f552) Co-authored-by: Sofhia Az-Zahra <sofhiaazzhr@users.noreply.huggingface.co>079782d -
/fix check and help tool (#8)
- /fix data_catalog model + CatalogStore to dedorch schema (data → catalog_payload) (09857fc52486354f53e752e3ea329b064a9e4c4b) - [NOTICKET] fix(help): lock reply language to user's language on button path (cb7f5ac484ad4a510e68faf5291091958b6d2f42) - /fix default SKIP_INIT_DB=true for dedorch cutover (skip init_db on Go-owned schema) (781b93c6b8744209a1101629b5170175e9212592) - /fix surface catalog foreign keys to the planner (FK-backed joins) (446c57524e932fcdbb0ddecc049189c443b6ae97) - [NOTICKET] feat(eval): add help-skill eval harness + goal-based language fallback (cbdbefb7ab0ffa36949713f18422213db480a959) - [NOTICKET] fix(eval): update readiness eval to post-KM-652 floor (drop problem_validated) (6f46e81bdeb1eb987f9dac8af0e22a975474cbb1) - /fix infer FKs for FK-less dedorch catalog + log repr(e) in db executor (3669290474583ae011f5ed5e50b94dad146fbc77) - Merge eval/help + readiness eval fix into PR #8 (5f4818a8e38f93988ab5756f3a06c94645826b15) - /docs REPO_STATUS: FK inference (FK-…3743cfe
-
/fix v2 chat stream api update to analyses_messages (#7)
- [NOTICKET] fix(db): reconcile analyses schema + migrate chat to analyses_messages (283eb0e4653acfe9311f42e3bb12d0490b8c9751)0066161 -
feat/ Endpoint Restructure (#5)
- [KM-686] Unwire Non-AI Routers from Main + Swagger (0b2d6785801ecc4d58a32580b1a9ef6238059de2) - [NOTICKET] docs: pr/5 sprint tracker + endpoint-restructure contract + REPO_STATUS banner (ce7be178428cadf1884a77d3d1f1398dccf32f6e) - [KM-687] Add Dedicated /tools/help Endpoint + Regroup Tools List (a881d38851470bf685990fdb554417da4fc1eccd) - [KM-688] feat(api): v2 chat pilot + regroup report under /tools; adopt lead API contracts (ad2ce619b51c234a8cd1c3772417a9a542a9a40d) Co-authored-by: Sofhia Az-Zahra <sofhiaazzhr@users.noreply.huggingface.co>3bacc1d
-
feat/Analysis State & Report Rework (#4)
- [NOTICKET] Add project repo documentation (ade9c0c635b1bb6f171a3f4e710e6d0f9bae28f3) - [KM-674] feat(report): adapt report generator to objective + business_questions (9bd8ec51fdcd5057b5e8ba6b219a7d9dce945144) - [NOTICKET] Add revision plan md file (e0384e1dc600b2496f96cbba152e616d65650f07) - chore(docs): tidy root markdown — archive stale docs, delete superseded ones (4835fb85915bd69079fb43d7c602774d514e02ae) - [KM-652] refactor: remove problem_statement skill + problem_validated gate (057e0b24b56dd697603d183f508cb1e8a87268fd) - [KM-678] feat(tools): trim FE slash menu to /help + /report (fed17ccc98ec523088c482673132763826f86701) - [NOTICKET] docs: sync DEV_PLAN status (#8/#9/#20) (e936cfafdfde1385fe16bd7e3796e7d46c193197) - [KM-679] fix(help): drop problem_statement refs after KM-652 (0bec4725db572d492634ced6a80ef6e65d075edc) - [KM-680] feat(report): show author display name (users.fullname) (9bccc122878fbdbae0ac1bd0b4316f5ea8af658c) - [NOTICKET] docs: add API_ENDPOINTS.md (FE surf…0e02a0f
-
feat/Knowledge & Data Tools (#3)
- [KM-641] refactor(tools): trim analytics registry to 4 active tools (66e2e4df66f1abf7eaa7e442d9900d428696ece4) - [NOTICKET] docs: add checkpoint plan for 2026-06-17 sync (8c1bb63ebdee02f9db0da9fc2b2269823b0a7688) - [KM-642] refactor(tools): rename data-access tools to data/knowledge naming (c38c0c29d3e6b245f67d03f2c35e451900e1abdb) - [KM-643] feat(tools): merge data sources into data_check + add knowledge_check (4bd5f1efdc560a64092cc8df672a7990fa949b59) - [NOTICKET] docs: record KM-642/643 in checkpoint plan + PROGRESS (4c57588b90fe0cac8d0d4d22cfe5701fc9eb52dd) - [NOTICKET] fix(chat): scope response cache by user_id + drop TTL to 1h (R5) (b701e95d300c7d2480a3608b2d4da6dfe102b19a) - [NOTICKET] feat(slow-path): persist AnalysisRecord via PostgresAnalysisStore (09f845188226dd01633cf74525caa569e4a7d37a) - [NOTICKET] Adopt verb-first skill naming (2d6406def7ed45edd1226e96645ba2a5cdbfa3d0) - [NOTICKET] docs: sync checkpoint plan — verb-first tool names + report-as-API (3b399f84d73b0d98bd99…0721bb4
-
feat/Planner Agent (#2)
- [KM-567][AI] Planner agent: contracts, schemas, inputs, registry (be96601ad46c00e8e789768dd6e89c2db827bde4) - [KM-567][AI] Planner agent: prompt + few-shot examples (83ba6b1743370145454d9315224eeb7b2d12ac18) - [KM-567][AI] Planner agent: validator + service (72306d0ce92c76d60117a20c701c7f8185bcfeef) - [KM-567] docs: record Phase 3 Planner agent in PROGRESS.md (ba2fa8892392028c8d13646c09d1155bbf34e703) - [KM-567][AI] Planner agent: fix PII leak + placeholder/retry robustness (6b3637dda097f16cd98d4b9ad6094fdaed6d1346) - [KM-624] Implement Compute Functions Tools (78c598c22d2f2a14229a83c3f43fa98c5d520ae7) - [KM-624][AI] Planner: realign stub registry + examples to composite analyze_* tools (93a24dabf48d8121e981cc470c835cb10badb62a) - [KM-624] docs: record tool taxonomy + ownership revision in PROGRESS (f3461142542f6216aff23b30a1321dfb4654afdc) - [KM-626][AI] Slow-path agent: seam contracts + TaskRunner (ac310de551d0888ccfef31e981e22d88f54c6a38) - [KM-626][AI] Slow-path agent: Assembler…81e5fe7
-
[KM-582][DED][AI] Fix Retrieval in Agentic Service
ticket: https://bukittechnology.atlassian.net/browse/KM-582 fix: replace LangChain ORM retrieval with raw SQL and fix pgvector collection name - Rewrite DocumentRetriever.retrieve() using raw SQL cosine/manhattan queries instead of LangChain PGVector ORM, bypassing asyncpg type-mapping issues (id String vs UUID column, jsonb_path_match binding quirks) - Fix _COLLECTION_NAME from "document_embeddings" to "documents" to match the collection name set by the Golang ingestion service - Fix collection_name in vector_store.py to match consistently - Fix Redis chat cache to store {response, sources} dict so cached replies also populate message_sources table - Add cache management endpoints: DELETE /chat/cache, /chat/cache/room/{id}, /retrieval/cache/{user_id} - Invalidate retrieval cache automatically after document processing - Update intent_router prompt: route topical/knowledge questions to unstructured even without explicit document mention; prefer unstructured when ambiguous…61c746f
-
feat/Catalog Retrieval System (#1)
- initial commit (8557a2045ca2c0873e07efdf6227064b83e4a1e5) - initial structure (efc0c0a8b2444014cbe74f04617c3c974d9915be) - [KM-553] initialize shared contract (f31f6731692b0199d8cb5c5d29dffa466d6d4ca0) - [KM-553] migrate retrieval layer and remove obsolete rag/tools modules (df220ea47c96eb8a1efa07c6eebef4604fc308d6) - [NOTICKET] catalog enricher + structured pipeline + on_db_registered (77ea82d29d86400c5ed30ac154be8df6a7e897eb) - Merge commit 'refs/pr/1' of https://huggingface.co/spaces/DataEyond/Agentic-Service-Data-Eyond-Catalog into pr/1 (0ae8717c7efce2cda14fe4b8caecd774459b1f6e) - [NOTICKET] SqlCompiler (Postgres) + DbExecutor (212dad360714508c1aa607995039e6818fa40f78) - Merge commit 'refs/pr/1' of https://huggingface.co/spaces/DataEyond/Agentic-Service-Data-Eyond-Catalog into pr/1 (faf8a4f6d7e06ccf1ce84c2e7f4990c79f27f843) - TabularIntrospector + on_tabular_uploaded trigger + 31 tests (ca425208969b72a20ed76f86ef0faa1a0e912339) - [KM 556] add columns field to QueryResult + update…6bff5d9
-
Merge dev_new to main (improve retriever and add querying) (#13)
- [noticket] add gitignore (c87f27f458854787102eebc110b178c2572ef8a6) - [NOTICKET]: add document pipeline, simplify document API (fb871f3d7db9c5a9c95a012761c4180a432e7e4b) - [NOTICKET]: update folder document_pipelines after pipelines (a4cf97ab3890e35831c0043a1d411c17d84f374b) - [NOTICKET][DB] refactor code to new repo (7f3bb9782bb9b6ace69e6be35377c12757a2f81d) - [KM-441] add mean and median (9b5933420821187e73bb72a896e28d7adf6d6137) - [NOTICKET] new metadata format for cleaner code (6b590d94c398ac4966a0e376f2809aa52c5ba022) - update document (5a69e0eecf80dd807565dbc369374e41450c37fc) - delete duplicate file (3848d7b262745b758069e3ab8089437ced42a45f) - edit document for new pipeline (425e021053c4de65e2598b0f5554b7c1044a904c) - [NOTICKET]: add CSV and XLSX file type (31920c3bc6f9faf9e07095a02fc1faf08adc246e) - [DB] fix/rename db_pipeline.py (d913315c356d741cc7a5a5b1f8e36ba41397f2ab) - [NOTICKET][DB] menyesuaikan format struktur db_pipeline sesuai dengan file lain (e13a9017e0f7fd26ef9b8a…52999bc
-
[NOTICKET] add total token logging (#9)
- [NOTICKET] add token logging (34eb194ed4c3f31ccd968390d1c05ca9547edafe)d973099
-
[KM-467] [DED][AI] Orchestration Agent - Init
- https://bukittechnology.atlassian.net/browse/KM-467027123c