logic-ingest

logic-ingest is a skill for Claude Code, Codex from NewJerseyStyle/plugin-logic-llm. It costs 0 tokens per session (607 once invoked), scanned A, original, MIT.

A batch importer that converts documents in a directory into symbolic logic programs and maintains a knowledge base. A knowledge base is an organized collection of facts and rules for later reasoning.

In plain words
What is it for?
Use it to ingest folders of contracts, regulations, policies, or other documents into Prolog or Clingo knowledge bases, including incremental or watched updates.
Why use it?
It avoids processing documents one by one and can update the stored logic when files are added or changed.

Skill for Claude CodeCodex

Part of the logic-llm plugin — 4 skills, 1 command, 8 agents, 2 hooks, 6 MCP servers shipped together

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/newjerseystyle/plugin-logic-llm/logic-ingest
Any agent
npx skills add NewJerseyStyle/plugin-logic-llm --skill logic-ingest
Clone the repo
git clone --depth 1 https://github.com/NewJerseyStyle/plugin-logic-llm

Made for: Claude Code, Codex.

Or install logic-llm, the plugin that ships this one along with the rest of its 4 skills, 1 command, 8 agents, 2 hooks, 6 MCP servers.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for logic-ingest

README.md
[![agentmods](https://agentmods.dev/badge/skills/newjerseystyle/plugin-logic-llm/logic-ingest.svg)](https://agentmods.dev/skills/newjerseystyle/plugin-logic-llm/logic-ingest)
Your own site
<a href="https://agentmods.dev/skills/newjerseystyle/plugin-logic-llm/logic-ingest"><img src="https://agentmods.dev/badge/skills/newjerseystyle/plugin-logic-llm/logic-ingest.svg" alt="Measured on agentmods" height="20"></a>
Per session 0 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 607 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.00607
Opus 5 $0.00000 $0.00303
Sonnet 5 $0.00000 $0.00121
Haiku 4.5 $0.00000 $0.00061

Measured 4d ago against content hash e4b76a3b80ed, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

logic-ingest scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/logic-ingest/SKILL.md · 86 lines

How it starts

The opening of the file, as written. The whole thing — 86 lines — stays where its author put it; the contents beside it link to each section on GitHub.

/logic-ingest

Batch ingest documents into the symbolic knowledge base with automatic incremental updates.

Description

This skill processes entire directories of documents, converting them to logic programs and maintaining a coherent, non-redundant knowledge base. It handles incremental updates when new documents are added.

Usage

/logic-ingest [options] <source-directory>

Options

  • --format <prolog|clingo> - Target format (default: prolog)
  • --output <directory> - Output directory for generated logic programs
  • --domain <name> - Domain name for organizing the knowledge base
  • --watch - Watch for new files and auto-ingest
  • --incremental - Only process new or modified files
  • --merge - Merge all outputs into a single knowledge base file

Examples

/logic-ingest --format prolog --domain legal ./contracts/
/logic-ingest --incremental --watch ./regulations/
/logic-ingest --merge --output ./kb/ ./policies/

Behavior

  1. Directory Scan: Identify all processable documents
  2. Change Detection: Compare with previous ingestion state
  3. Dependency Analysis: Determine processing order based on references
  4. Batch Conversion: Convert documents using /logic-convert
  5. Deduplication: Remove redundant predicates and rules
  6. Consistency Check: Validate the combined knowledge base
  7. Registry Update: Update registry with all new entries

Document Types Supported

  • Plain text (.txt)
  • Markdown (.md)
  • PDF (requires external tool)
  • Legal documents (contracts, regulations, policies)
  • Structured data (JSON, YAML) with schema inference

Incremental Updates

When --incremental is used:

  • Only new or modified files are processed
  • Existing predicates are preserved
  • Conflicts are detected and reported
  • Registry is updated atomically

Output Structure

output/
├── predicates.pl          # All predicate definitions
├── facts/
│   ├── document1.pl       # Facts from each document
│   └── document2.pl
├── rules/
│   ├── inferred.pl        # Derived rules
│   └── explicit.pl        # Explicit rules from documents
├── registry.json          # Local registry snapshot
└── manifest.json          # Ingestion metadata

Read the full file on GitHub · 86 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 4d ago First seen · 86 lines · 0 tokens per session scan A e4b76a3b80ed

Subscribe to this mod's changes

logic-ingest is a skill published in the GitHub repository NewJerseyStyle/plugin-logic-llm (2 stars, last pushed 7mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 607 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.