§ Technology

How it works

This page documents KARTILYA.PH’s bounded retrieval and source-checking architecture. General Ask is under maintenance. Cases, Statutes, and source-bounded Passage Ask remain available through the public research desk. The system is an automated research aid, not legal advice or a substitute for professional judgment.

8,296 provisions · 57 instruments · 4,181 jurisprudence records · Gate 1 grounds statutory points and case holdings in retained source text

THE CORPUS · BUILT ONCETHE ANSWER · PER QUESTIONSourcesthird-party text · rulesStructuredprovisions + casesEmbedlegal vectorsQuestionin plain wordsExpandstatutory rewriteRetrievecosine top-kSynthesizegrounded + citedSource checkcompare citationsAnswerstatus shown
01

One corpus, structured

The statutory corpus contains 8,297 provisions across 57 instruments: the 1987 Constitution, major Codes, and selected statutes and rules. Most instruments are third-party reproductions published by the Arellano Law Foundation; procedural rules were sourced separately. A deterministic pipeline parses the material into addressable provisions and preserves instrument, chapter, and section context as structured metadata. Some base texts are enacted versions rather than current consolidated editions; the relevant reading pages carry currency notes.

02

A bounded jurisprudence snapshot

The jurisprudence catalog contains 4,181 records in a dated, incomplete snapshot from 2019 through July 29, 2026. Links between a decision and a statute record extracted citations; they do not by themselves establish a holding or application. Jurisprudence retrieval remains separate from the statutory synthesis described below.

03

Meaning-based retrieval

Statutory provisions and retained opinion-text chunks are embedded for semantic retrieval, so candidate materials can be matched by meaning rather than exact phrase. At query time the question is embedded and compared by cosine similarity with the statutory provisions. The question is also rewritten into denser statutory terminology, and the original and rewritten searches are interleaved. Thus, “can an arrested person stay silent?” can retrieve the custodial-investigation clause even though the question uses different terms.

your question+ statutory rewritenearest provisions by meaningevery provision + opinion, embedded oncecosine similarity · legal embedding space
Retrieval proposes candidate provisions by meaning; it does not determine whether a proposition is legally supported.
04

Grounded synthesis

The statutory synthesis model receives retrieved provisions, not related-decision metadata. It is instructed to use only the supplied statutory text, divide the answer into discrete points, and attach the cited provision to each point. A separate case-analysis path works only from bounded retained-opinion excerpts: it screens relevance and selects a concise verbatim holding passage. Where the retrieved corpus does not address the question, the response reports that coverage limit. The resulting answer remains automated research output and can be incomplete or wrong.

05

The citation firewall

Each statutory citation is resolved against the corpus, and every cited answer point is checked against the corresponding corpus passage. Case holding excerpts pass a separate boundary: the selected text must be found verbatim in the retained opinion; deterministic source-role checks reject quoted-authority blocks; then an independent check must confirm that it is the decision's relevant majority holding or application. The displayed holding is constructed from the canonical source passage, not separately generated. A failed, malformed, incomplete, or misattributed excerpt is omitted; the already-screened case card may remain without one. These checks concern source support and relevance, not completeness, currentness, or the application of law to a person’s facts.

CLAIM“A confession without counselis inadmissible.”CITED SOURCEConst. Art. III, Sec. 12(3)citation checkcompares the statementwith source text✓ support foundsource shown, review it⚑ review · ? unavailablesupport not confirmed
Each cited statutory point reports a check result. Unsupported points are flagged; incomplete or unavailable checks remain unavailable.

§ See it work

This fixed example illustrates a statutory answer whose two cited points completed the source-text check and were reported as verified. It is an illustration, not a legal opinion; other results may be flagged or unavailable.

§ Can an arrested person stay silent?

Yes, under the Constitution.
  • A person under custodial investigation has the right to remain silent and to competent, independent counsel, preferably of their own choice. ✓ 1987 Constitution · Art. III, Sec. 12(1)
  • Any confession or admission obtained in violation of this right is inadmissible in evidence against the person. ✓ 1987 Constitution · Art. III, Sec. 12(3)
Source check✓ 2 support checks

A fixed example for illustration. General Ask is under maintenance. Browse Statutes →

§ Why source checks matter

A general-purpose AI model can produce a confident legal answer while missing an exception, relying on an outdated rule, or misstating a citation. KARTILYA.PH narrows the task by supplying retrieved provisions and reporting source checks. That reduces some common failure modes, while leaving the need to check the law and the facts of the matter.

The source check assigns each cited statutory point a reported status after comparison with its corpus passage: verified, flagged, or unavailable. Failed and incomplete checks remain unavailable rather than receiving a verified status. Case holding excerpts are separately grounded in exact passages located in a retained opinion excerpt, then independently checked against those passages. These statuses describe the check performed; they do not guarantee the whole answer or its application to a particular matter.

Statutory and case synthesis remain separate: each uses its own retained source material and independent verification boundary. Review the cited source and consult a licensed Philippine lawyer for advice about a specific matter. Search case records →