Edge Rewrite
// HTMLRewriter · presentation

This page was redesigned at the edge.

Cloudflare fetched the original article and streamed it through HTMLRewriter to apply an entirely new visual system without rebuilding the source page.

// request.cf · coarse context

A page that knows where it met you.

Only coarse request metadata is shown. This demo does not display or persist visitor IP addresses.

Country
US
Cloudflare location
CMH
Connection
HTTP/2
Language
Not provided

Ray ID: a2624b92cd24aedd

Jump to content

Draft:Inthon

From Wikipedia, the free encyclopedia
  • Comment: We can't accept AI assisted drafts. In addition there is not sufficient sourcing for notability here, the sources are primary/non independent/self published. ChrysGalley (talk) 13:23, 18 July 2026 (UTC)

Inthon
ParadigmAgent-oriented, multi-paradigm
Designed byHarsha Vardhan
DeveloperHarVa DeepLabs
First appeared2026
Typing disciplineGradual, static AST checking, strong dynamic
PlatformPython-hosted environment
LicenseApache License 2.0
Filename extensions.inth
Websiteharvatechs.github.io/inthon/
Influenced by
Python, Rust, SQL, JavaScript

Inthon is a domain-specific, Python-hosted programming language designed for artificial intelligence agents, tool orchestration, and sandboxed execution. Developed in 2026 by Harsha Vardhan of HarVa DeepLabs, Inthon provides a compile-ready, statically checked syntax for expressing agent goals, tool calls, memory persistence, safety policies, and human-in-the-loop approval checkpoints.[1]

The language is designed to reduce the prompt token footprint of large language model (LLM) agents, validate interfaces prior to execution, and provide security boundaries when executing tools. Inthon compiles to Python code, JSON tool-call graphs, or directed acyclic graph (DAG) execution plans depending on the target runtime.[2] In July 2026, the language implementation was presented at the BangPypers (Bangalore Python Users Group) community meetup.[3]

Design and motivation

[edit]

Traditional autonomous agent architectures rely on Large Language Models executing workflows through natural language prompts or structured JSON or YAML schemas. This approach can introduce token overhead and execution errors due to non-deterministic parsing. Additionally, executing arbitrary Python or shell commands generated by an LLM exposes the host system to security risks.

Inthon was designed to address these limitations through three main components:

  • Token efficiency: A minimal, context-free grammar written in EBNF, designed to decrease the number of tokens required for an agent to express a plan.[2]
  • Capability-based sandbox: A security model that blocks system calls, unauthorized network connections, and private attribute access by default.[4]
  • Deterministic execution tracing: Output logs formatted in JSON to allow execution steps and tool invocations to be audit-logged and replayed.

Syntax and features

[edit]

Variables and constants

[edit]

Inthon utilizes lexical block scoping. Variables declared inside a block are restricted to that scope. Mutable variables are declared using the let keyword, while constants are declared with const. Types are optionally annotated using a colon.

let name: str = "INTHON"
let version: float = 1.0
const max_retries: int = 3
let models: list[str] = ["gpt-4o", "gemini-3.5"]

Type system

[edit]

The language features a gradual type system. Standard primitive types (str, int, float, bool, bytes, none, any) are supported alongside agent-specific types:

  • Goal: High-level task description.
  • Plan: Ordered execution steps.
  • ToolCall and ToolResult: Records for tool execution tracking.
  • Trace: Representation of the execution trace.
  • MemoryRef: Persistent memory handle.
  • Approval: Record of human-in-the-loop decisions.

Structured agent blocks

[edit]

The execution lifecycle of an agent is defined inside an agent block. This container encapsulates the agent's goal, input/output interfaces, runtime policies, and execution instructions.

agent Researcher {
    goal "Retrieve papers on room-temperature superconductors"
    inputs {
        query: str
        limit: int
    }
    outputs {
        papers: list[dict]
    }
    
    use tool web.search
    
    policy {
        max_tool_calls: 10
        max_cost_usd: 0.05
    }
    
    plan {
        let raw_results = web.search(query: query, count: limit)
        return raw_results
    }
}

Control flow

[edit]

Inthon supports conditional statements (if-else), loops (while, for-in), and functions (fn). Block-ending expressions that lack a semicolon or return keyword are implicitly returned.

fn multiplier(factor: int) -> fn(int) -> int {
    fn inner(x: int) -> int {
        x * factor
    }
    return inner
}

Agent-native primitives

[edit]
  • Approval gateways: Halts script execution to await human approval before executing sensitive operations.
  • Episodic memory: Integrates a local SQLite database to persist semantic statements, querying them via cosine similarity search on vector embeddings.
  • Retry loops: Supports automated retry blocks with exponential backoff and randomized jitter to handle transient network errors.

Security model

[edit]

Inthon restricts operations using a capability-based security model. When interacting with the host Python environment, the language utilizes a security system called PyBridge. This system enforces security at two levels:

  1. Import hook interception: PyBridge installs a custom meta-importer hook in Python's sys.meta_path. The hook intercepts and blocks imports of modules outside an allowlist. Standard operating system, shell, and network modules (such as os, sys, subprocess, and socket) are blocked by default.
  2. Namespace proxying: Allowed libraries are wrapped in proxy objects (InthonPyObject) that override attribute access (__getattribute__, __setattr__). This prevents programs from accessing private module properties or traversing namespaces to execute shell commands.

Execution and compilation

[edit]

The compilation pipeline comprises a Lark-based concrete syntax parser, a semantic analyzer for type checking, and an intermediate representation (IR) builder.

Programs are executed using one of two modes:

  • AST interpreter: Parses the concrete syntax tree into an abstract syntax tree (AST) and evaluates statements sequentially.
  • InthonVM: A stack-based bytecode virtual machine. The compilation pipeline lowers the AST into a JSON-compatible bytecode format, which is executed by the virtual machine.

References

[edit]
  1. "Inthon". Esolang Wiki. June 2026. Retrieved 2026-07-18.
  2. 1 2 INTHON Research Group (June 2026). INTHON: An Agent-Level Language for AI-Native Execution, Tool Orchestration, and Machine-Speed Workflows (Technical report). HarVa DeepLabs.
  3. "BangPypers (Bangalore Python Users Group)". Meetup. 2026-07-18. Retrieved 2026-07-18.
  4. "inthon: Agent-level programming language for AI-native workflows". Python Package Index. 2026-07-18. Retrieved 2026-07-18.
[edit]