ax-python-signature

ax-python-signature is a skill for Claude Code, Codex from ax-llm/ax. It costs 35 tokens per session (2,217 once invoked), scanned A, original, Apache-2.0.

A Python guide for defining clear input and output shapes for axllm programs. It explains signatures, field types, JSON Schema, validation, and typed tool arguments.

In plain words
What is it for?
Use it to declare contracts for programs and tools, generate JSON schemas, validate results, and describe bounded class outputs.
Why use it?
It helps keep prompts, tool inputs, and agent results consistent and makes their expected data structure explicit.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to declare contracts for programs and tools, generate JSON schemas, validate results, and describe bounded class outputs.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/ax-llm/ax/ax-python-signature
About the project

Ax is a TypeScript-first programming framework for building applications with large language models through typed generation, agents, workflows, and optimization tools. It is intended for developers who want one model for LLM programs across TypeScript, Python, Java, C++, Go, Rust, and other runtimes.

ax-llm/ax · 2,968 stars · on GitHub · axllm.dev

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.

Any agent
npx skills add ax-llm/ax --skill ax-python-signature
Clone the repo
git clone --depth 1 https://github.com/ax-llm/ax

Made for: Claude Code, Codex.

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 ax-python-signature

README.md
[![agentmods](https://agentmods.dev/badge/skills/ax-llm/ax/ax-python-signature/github.svg)](https://agentmods.dev/skills/ax-llm/ax/ax-python-signature)
Your own site
<a href="https://agentmods.dev/skills/ax-llm/ax/ax-python-signature"><img src="https://agentmods.dev/badge/skills/ax-llm/ax/ax-python-signature/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for ax-python-signature

Your own site · 80×15
<a href="https://agentmods.dev/skills/ax-llm/ax/ax-python-signature"><img src="https://agentmods.dev/badge/skills/ax-llm/ax/ax-python-signature.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 35 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,217 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
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.1 $0.00035 $0.02217
Opus 5.5 $0.00014 $0.00887
Sonnet 5.5 $0.00007 $0.00443
Haiku 4.5 $0.00003 $0.00222

Measured yesterday against content hash 6c61975320e0, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

ax-python-signature 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 yesterday.

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.

packages/python/skills/ax-python-signature/SKILL.md · 148 lines

How it starts

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

Ax Signatures For Python

This skill helps an agent write Python code with the generated Ax package axllm. Use the generated package API, examples, and manifests; do not import TypeScript-only APIs unless you are editing the TypeScript package.

When To Use

  • Declare input and output contracts with native generated-package APIs.
  • Generate JSON-schema-compatible shapes for outputs, tools, prompts, and validation.
  • Keep Standard Schema and TypeScript-only helper libraries out of generated-language code.

Package Facts

  • Language: Python.
  • Package: axllm.
  • Package API docs: API.md and axir-api.json.
  • Capability manifest: axir-capabilities.json.
  • Runnable examples: examples/.
  • Real network support: yes.
  • Scripted no-key transport support: yes.
  • Runtime profiles: javascript-quickjs, python-pyodide.

Core Pattern

from axllm import s

sig = s("question:string -> answer:string")
schema = sig.to_json_schema("outputs")

More Patterns

Simple string contract

Use the string form when field names and types are enough.

from axllm import ax

program = ax("questionText:string -> answerText:string")

Bounded class output

A class field constrains the model to a known label set.

router = ax(
    'messageText:string -> routeClass:class "support, sales, engineering"'
)

Fluent constraints

Python exposes the native fluent builder for validation constraints and objects.

from axllm import f

signature = (
    f()
    .input("contactEmail", f.string("Contact email").email())
    .output("partySize", f.number("Guests").min(1).max(12))
    .output("bookingCode", f.string().regex(r"^[A-Z]{3}-\d{4}$"))
    .build()
)

JSON schema

Render the output contract for tools, validators, or external consumers.

schema = signature.to_json_schema("outputs")

Reuse the signature

Pass one built signature into AxGen and call it like any other program.

program = ax(signature)
output = program.forward(client, inputs)

Read the full file on GitHub · 148 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. yesterday Changed 6c61975320e0
  2. 2d ago Changed 6770a3638c17
  3. 4d ago Changed ad6615cd6618
  4. 5d ago Changed ab6dc217a66a
  5. 7d ago Changed · +6 lines b06d852694f0
  6. 9d ago Changed b4733853c09b
  7. 11d ago Changed · +10 lines 0dbae6dd4466
  8. 14d ago Changed 325b4e30f5c1
  9. 15d ago Changed · +10 lines fa1e43b1daa1
  10. 16d ago First seen · 122 lines · 35 tokens per session scan A bb9a26e29f8c

Subscribe to this mod's changes

ax-python-signature is a skill published in the GitHub repository ax-llm/ax (2,968 stars, last pushed 2d ago), licensed Apache-2.0. It adds 35 tokens to every session and 2,217 once invoked, about $0.0001 per session on Opus 5.5. 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-09-03.

Related

Other skills, from other repositories

stripe-projects

Use after E2B sandbox/API access has been provisioned through Stripe Projects and the user needs to use the resulting E2B API key with the E2B CLI, JavaScript SDK, Python SDK, or Code Interpreter SDK.

e2b-dev/E2B · 51 tokens

migrating-mastra-to-pydantic-ai

Migrate TypeScript Mastra applications to Python with Pydantic AI and, only when needed, Pydantic AI Harness. Use when source code imports @mastra/ or relies on Mastra agents, tools, workflows, memory, processors, streaming, approvals, skills, or subagents.

pydantic/pydantic-ai · 73 tokens

migrating-vercel-ai-sdk-and-eve-to-pydantic-ai

Migrate TypeScript Vercel AI SDK or Eve applications to Python with Pydantic AI and, only when needed, Pydantic AI Harness. Use when source code imports ai, @ai-sdk/, or eve, or relies on generateText, streamText, ToolLoopAgent, useChat, Eve agents, tools, skills, subagents, approvals, sessions, channels, schedules…

pydantic/pydantic-ai · 107 tokens

migrating-pi-to-pydantic-ai

Migrate TypeScript Pi coding-agent applications, extensions, or packages to Python with Pydantic AI and Pydantic AI Harness. Use when source code imports @earendil-works/pi-, calls createAgentSession, registers Pi extensions, or relies on Pi tools, hooks, skills, sessions, compaction, providers, TUI, RPC, or packages.

pydantic/pydantic-ai · 88 tokens

python-repl

Interactive Python REPL automation with common helpers and best practices.

gptme/gptme · 15 tokens

claude-api

Anthropic Claude API patterns for Python and TypeScript. Covers Messages API, streaming, tool use, vision, extended thinking, batches, prompt caching, and Claude Agent SDK. Use when building applications with the Claude API or Anthropic SDKs.

hashgraph-online/awesome-codex-plugins · 53 tokens