# THIS FILE IS AUTOMATICALLY GENERATED BY CARGO
#
# When uploading crates to the registry Cargo will automatically
# "normalize" Cargo.toml files for maximal compatibility
# with all versions of Cargo and also rewrite `path` dependencies
# to registry (e.g., crates.io) dependencies.
#
# If you are reading this file be aware that the original Cargo.toml
# will likely look very different (and much more reasonable).
# See Cargo.toml.orig for the original contents.

[package]
edition = "2024"
rust-version = "1.88"
name = "swink-agent"
version = "0.7.8"
build = false
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "Core scaffolding for running LLM-powered agentic loops"
readme = "README.md"
keywords = [
    "llm",
    "agent",
    "ai",
    "streaming",
    "tools",
]
categories = [
    "development-tools",
    "api-bindings",
    "asynchronous",
]
license = "MIT"
repository = "https://github.com/SuperSwinkAI/Swink-Agent"
resolver = "2"

[package.metadata.docs_rs]
all-features = true
rustdoc-args = [
    "--cfg",
    "docsrs",
]

[features]
artifact-store = ["dep:bytes"]
artifact-tools = ["artifact-store"]
builtin-tools = ["dep:sha2"]
default = [
    "builtin-tools",
    "transfer",
]
hot-reload = ["dep:notify"]
otel = [
    "dep:tracing-opentelemetry",
    "dep:opentelemetry",
    "dep:opentelemetry_sdk",
    "dep:opentelemetry-otlp",
    "dep:tracing-subscriber",
]
plugins = []
testkit = []
tiktoken = ["dep:tiktoken-rs"]
transfer = []

[lib]
name = "swink_agent"
path = "src/lib.rs"

[[test]]
name = "abort_turn_end_reason"
path = "tests/abort_turn_end_reason.rs"

[[test]]
name = "ac_context"
path = "tests/ac_context.rs"

[[test]]
name = "ac_lifecycle"
path = "tests/ac_lifecycle.rs"

[[test]]
name = "ac_resilience"
path = "tests/ac_resilience.rs"

[[test]]
name = "ac_structured"
path = "tests/ac_structured.rs"

[[test]]
name = "ac_tools"
path = "tests/ac_tools.rs"

[[test]]
name = "agent"
path = "tests/agent.rs"

[[test]]
name = "agent_continuation"
path = "tests/agent_continuation.rs"

[[test]]
name = "agent_event_serde"
path = "tests/agent_event_serde.rs"

[[test]]
name = "agent_loop"
path = "tests/agent_loop.rs"

[[test]]
name = "agent_models"
path = "tests/agent_models.rs"

[[test]]
name = "agent_steering"
path = "tests/agent_steering.rs"

[[test]]
name = "agent_structured"
path = "tests/agent_structured.rs"

[[test]]
name = "approval"
path = "tests/approval.rs"

[[test]]
name = "composed"
path = "tests/composed.rs"

[[test]]
name = "context_compaction"
path = "tests/context_compaction.rs"

[[test]]
name = "emit"
path = "tests/emit.rs"

[[test]]
name = "error"
path = "tests/error.rs"

[[test]]
name = "event_forwarder"
path = "tests/event_forwarder.rs"

[[test]]
name = "fallback"
path = "tests/fallback.rs"

[[test]]
name = "fn_tool"
path = "tests/fn_tool.rs"

[[test]]
name = "handle"
path = "tests/handle.rs"

[[test]]
name = "integration"
path = "tests/integration.rs"

[[test]]
name = "loop_overflow"
path = "tests/loop_overflow.rs"

[[test]]
name = "message_provider"
path = "tests/message_provider.rs"

[[test]]
name = "messaging"
path = "tests/messaging.rs"

[[test]]
name = "model_connections"
path = "tests/model_connections.rs"

[[test]]
name = "no_default_features"
path = "tests/no_default_features.rs"

[[test]]
name = "otel_spans"
path = "tests/otel_spans.rs"

[[test]]
name = "pause_resume"
path = "tests/pause_resume.rs"

[[test]]
name = "plugin_integration"
path = "tests/plugin_integration.rs"

[[test]]
name = "plugin_registry"
path = "tests/plugin_registry.rs"

[[test]]
name = "pre_dispatch_panic_rollback"
path = "tests/pre_dispatch_panic_rollback.rs"

[[test]]
name = "property"
path = "tests/property.rs"

[[test]]
name = "public_api"
path = "tests/public_api.rs"

[[test]]
name = "registry"
path = "tests/registry.rs"

[[test]]
name = "retry"
path = "tests/retry.rs"

[[test]]
name = "schema"
path = "tests/schema.rs"

[[test]]
name = "stream"
path = "tests/stream.rs"

[[test]]
name = "stream_accumulate_errors"
path = "tests/stream_accumulate_errors.rs"

[[test]]
name = "stream_middleware"
path = "tests/stream_middleware.rs"

[[test]]
name = "stream_resilience"
path = "tests/stream_resilience.rs"

[[test]]
name = "stress_concurrent_tools"
path = "tests/stress_concurrent_tools.rs"

[[test]]
name = "stress_conversation"
path = "tests/stress_conversation.rs"

[[test]]
name = "stress_orchestrator"
path = "tests/stress_orchestrator.rs"

[[test]]
name = "stress_tool_dispatch"
path = "tests/stress_tool_dispatch.rs"

[[test]]
name = "sub_agent"
path = "tests/sub_agent.rs"

[[test]]
name = "tool"
path = "tests/tool.rs"

[[test]]
name = "tool_execution_policy"
path = "tests/tool_execution_policy.rs"

[[test]]
name = "tool_middleware"
path = "tests/tool_middleware.rs"

[[test]]
name = "tools"
path = "tests/tools.rs"

[[test]]
name = "transfer"
path = "tests/transfer.rs"

[[test]]
name = "types"
path = "tests/types.rs"

[[bench]]
name = "context"
path = "benches/context.rs"
harness = false

[dependencies.bytes]
version = "1"
optional = true

[dependencies.chrono]
version = "0.4"
features = ["serde"]

[dependencies.futures]
version = "0.3"

[dependencies.jsonschema]
version = "0.28"

[dependencies.notify]
version = "7"
optional = true

[dependencies.opentelemetry]
version = "0.31"
optional = true

[dependencies.opentelemetry-otlp]
version = "0.31"
features = ["grpc-tonic"]
optional = true

[dependencies.opentelemetry_sdk]
version = "0.31"
features = ["rt-tokio"]
optional = true

[dependencies.rand]
version = "0.10"

[dependencies.regex]
version = "1"

[dependencies.schemars]
version = "1"

[dependencies.serde]
version = "1"
features = [
    "derive",
    "rc",
]

[dependencies.serde_json]
version = "1"

[dependencies.sha2]
version = "0.11"
optional = true

[dependencies.thiserror]
version = "2"

[dependencies.tiktoken-rs]
version = "0.6"
optional = true

[dependencies.tokio]
version = "1"
features = ["full"]

[dependencies.tokio-stream]
version = "0.1"

[dependencies.tokio-util]
version = "0.7"

[dependencies.toml]
version = "0.9"

[dependencies.tracing]
version = "0.1"

[dependencies.tracing-opentelemetry]
version = "0.32"
optional = true

[dependencies.tracing-subscriber]
version = "0.3"
features = ["registry"]
optional = true

[dependencies.uuid]
version = "1"
features = ["v4"]

[dev-dependencies.criterion]
version = "0.8"
features = ["html_reports"]

[dev-dependencies.dotenvy]
version = "0.15"

[dev-dependencies.insta]
version = "1"
features = ["json"]

[dev-dependencies.opentelemetry]
version = "0.31"

[dev-dependencies.opentelemetry_sdk]
version = "0.31"
features = [
    "testing",
    "rt-tokio",
]

[dev-dependencies.pretty_assertions]
version = "1"

[dev-dependencies.proptest]
version = "1"
features = ["std"]
default-features = false

[dev-dependencies.tempfile]
version = "3"

[dev-dependencies.tokio]
version = "1"
features = [
    "full",
    "full",
    "test-util",
]

[dev-dependencies.tracing-opentelemetry]
version = "0.32"

[dev-dependencies.tracing-subscriber]
version = "0.3"
features = ["registry"]

[dev-dependencies.wiremock]
version = "0.6"

[lints.clippy]
missing_errors_doc = "allow"
missing_panics_doc = "allow"
module_name_repetitions = "allow"
must_use_candidate = "allow"
redundant_pub_crate = "allow"

[lints.clippy.all]
level = "warn"
priority = -1

[lints.clippy.nursery]
level = "warn"
priority = -1

[lints.clippy.pedantic]
level = "warn"
priority = -1

[lints.rust]
unsafe_code = "forbid"

[profile.dev]
split-debuginfo = "unpacked"

[profile.release]
lto = "thin"
codegen-units = 1
