Skip to main content

goshikq-ai (Python SDK)

Python SDK for Goshikq, the outcome-driven, model-independent AI agent framework. The SDK declares agents, goals, and tool contracts; the Goshikq Rust runtime owns execution, policy enforcement, persistence, and verification.

Status: package 1.0.1 is prepared in this branch and is not on PyPI. The published stable runtime remains GitHub Release v1.0.0. v1.0.0-rc.1 is superseded due to its older JWT dependency. v1.0.0-rc.2 remains published. Do not run pip install goshikq-ai until an owner publishes the package.

Install

pip install -e ".[dev]"            # from sdk/python in the repo
pip install -e ".[openai]"         # optional provider adapters
pip install -e ".[anthropic]"

Requires a running Goshikq runtime (default http://127.0.0.1:7400, override with GOSHIKQ_RUNTIME_URL).

Minimal example

from goshikq_ai import Agent, Goal, Runtime, StateSnapshot, tool
from goshikq_ai.models import MockModel, ModelTurn

@tool(effect="read_only")
def lookup_order(order_id: str) -> dict:
    return {"order_id": order_id, "status": "paid"}

def order_was_looked_up(state: StateSnapshot) -> bool:
    return state.get("lookups") == 1

agent = Agent(
    name="hello-agent",
    model=MockModel(script=[ModelTurn(tool_calls=[("lookup_order", {"order_id": "A-1"})]), ModelTurn(content="done")]),
    tools=[lookup_order],
)
result = Runtime(agent, state_provider=...).run_sync(Goal(description="Look up order A-1", success=order_was_looked_up))
print(result.status, result.verification_status)

result.verified is True only when the runtime completed the run and the goal predicate held against a fresh StateSnapshot. Without a state provider the run ends UNVERIFIED.

Concepts

Type Purpose
@tool(effect=..., risk=..., requires_approval=..., verifier=...) Action contract. effect drives retry safety in the runtime.
Goal(description, success=, invariants=) Predicates evaluated by the runtime against authoritative state, never model claims.
StateProvider Returns a StateSnapshot of the real system (DB, API) on request.
Agent(name, model, tools) model is "provider/model" or a ModelAdapter (e.g. MockModel).
Runtime(agent, state_provider=) Submits the run and serves worker requests until the run is terminal.

Development

pytest
ruff check src tests
mypy

Metadata

Release files for goshikq-ai 1.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for goshikq-ai 1.0.1
File Size Uploaded Provenance Actions
goshikq_ai-1.0.1.tar.gz 31.9 kB With provenance Details for goshikq_ai-1.0.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for goshikq-ai 1.0.1
File Interpreter ABI Platform Actions
goshikq_ai-1.0.1-py3-none-any.whl Python 3 none any Details for goshikq_ai-1.0.1-py3-none-any.whl

Total release size: 70.5 kB

Release files / goshikq_ai-1.0.1.tar.gz

Download URL goshikq_ai-1.0.1.tar.gz
Size 31.9 kB
Tags Source
SHA-256 checksum
How to use checksums
50be6ce55677fc5f3d617e8edc39012f9b398cd9914c22bfcfde139fdf9e107a
BLAKE2b-256 checksum
How to use checksums
23d9fd6c4fc0e2a55a5957bea22240984ad5f60e8d5ace57425cdaa87ee15065
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 28, 2026.

Transparency log

Release files / goshikq_ai-1.0.1-py3-none-any.whl

Download URL goshikq_ai-1.0.1-py3-none-any.whl
Size 38.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e1421064240484f40c7e65db80b0d9b21f51b9622dcdb4fbc639ad1c8556cbb5
BLAKE2b-256 checksum
How to use checksums
3fe4c0a1f5613f84290449480db618b48b9b323d83e2af53b22549372a7bfc2d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 28, 2026.

Transparency log

Security for goshikq-ai 1.0.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for goshikq_ai-1.0.1.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 28, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

1.0.1 This release

2 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page