[package]
edition = "2021"
name = "openai-protocol"
version = "1.2.0"
authors = [
"Simo Lin <linsimo.mark@gmail.com>",
"Chang Su <mckvtl@gmail.com>",
"Keyang Ru <rukeyang@gmail.com>",
]
build = false
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "OpenAI-compatible API protocol definitions and types"
readme = false
keywords = [
"openai",
"llm",
"api",
"protocol",
"types",
]
categories = [
"api-bindings",
"data-structures",
]
license = "Apache-2.0"
repository = "https://github.com/lightseekorg/smg"
[features]
axum = ["dep:axum"]
default = []
[lib]
name = "openai_protocol"
path = "src/lib.rs"
[dependencies.axum]
version = "0.8.6"
optional = true
[dependencies.bitflags]
version = "2.10.0"
[dependencies.chrono]
version = "0.4"
[dependencies.rand]
version = "0.9.2"
[dependencies.serde]
version = "1.0"
features = ["derive"]
[dependencies.serde_json]
version = "1.0"
features = ["preserve_order"]
[dependencies.serde_with]
version = "3"
features = ["macros"]
[dependencies.tokio]
version = "1.42.0"
[dependencies.tracing]
version = "0.1"
[dependencies.validator]
version = "0.20.0"
features = ["derive"]
[lints.clippy]
absolute_paths = "warn"
allow_attributes = "warn"
assigning_clones = "warn"
cloned_instead_of_copied = "warn"
dbg_macro = "deny"
default_trait_access = "allow"
disallowed_methods = "warn"
doc_lazy_continuation = "allow"
expect_used = "warn"
explicit_into_iter_loop = "warn"
explicit_iter_loop = "warn"
if_not_else = "warn"
ignored_unit_patterns = "warn"
inconsistent_struct_constructor = "warn"
inefficient_to_string = "warn"
large_futures = "warn"
manual_assert = "warn"
manual_string_new = "warn"
match_bool = "warn"
match_same_arms = "allow"
match_wildcard_for_single_variants = "warn"
must_use_candidate = "allow"
needless_raw_string_hashes = "warn"
or_fun_call = "warn"
panic = "warn"
print_stderr = "warn"
print_stdout = "warn"
ref_option = "warn"
semicolon_if_nothing_returned = "warn"
single_component_path_imports = "warn"
single_match_else = "allow"
stable_sort_primitive = "warn"
todo = "deny"
trivially_copy_pass_by_ref = "warn"
unimplemented = "deny"
uninlined_format_args = "warn"
unnecessary_wraps = "warn"
unreachable = "deny"
unused_async = "warn"
unused_self = "warn"
unwrap_used = "deny"
[lints.rust]
unsafe_code = "deny"
unused_qualifications = "warn"