-
Notifications
You must be signed in to change notification settings - Fork 50
Expand file tree
/
Copy pathpyproject.toml
More file actions
179 lines (165 loc) · 5.17 KB
/
pyproject.toml
File metadata and controls
179 lines (165 loc) · 5.17 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[project]
name = "ai-bom"
dynamic = ["version"]
description = "AI Bill of Materials — discover and inventory all AI/LLM agents, models, and API integrations across your infrastructure."
readme = "README.md"
license = "Apache-2.0"
requires-python = ">=3.10"
authors = [
{ name = "Trusera", email = "info@trusera.dev" },
]
keywords = [
"ai", "bom", "security", "llm", "agents", "compliance",
"n8n", "shadow-ai", "sbom", "ai-security", "devsecops",
"mcp", "ai-agent", "cybersecurity", "red-teaming", "giskard",
"agentic-security", "eu-ai-act",
]
classifiers = [
"Development Status :: 4 - Beta",
"Intended Audience :: Developers",
"Intended Audience :: System Administrators",
"Intended Audience :: Information Technology",
"License :: OSI Approved :: Apache Software License",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Topic :: Security",
"Topic :: Software Development :: Quality Assurance",
"Topic :: Software Development :: Testing",
"Typing :: Typed",
]
dependencies = [
"typer>=0.9.0,<1.0",
"rich>=13.0.0,<16.0",
"pydantic>=2.0.0,<3.0",
"pyyaml>=6.0,<7.0",
"gitpython>=3.1.0,<4.0",
"requests>=2.28.0,<3.0",
"pathspec>=0.11.0,<2.0",
"tomli>=2.0.0,<3.0; python_version<'3.11'",
"jsonschema>=4.0,<5.0",
]
[project.optional-dependencies]
dashboard = [
"fastapi>=0.100.0,<1.0",
"uvicorn[standard]>=0.20.0,<1.0",
]
dev = [
"pytest>=7.0,<10.0",
"pytest-cov>=4.0,<8.0",
"ruff>=0.1.0,<1.0",
"mypy>=1.0,<2.0",
"types-PyYAML>=6.0,<7.0",
"types-requests>=2.28,<3.0",
"pip-audit>=2.6.0,<3.0",
]
docs = [
"mkdocs>=1.5,<2.0",
"mkdocs-material>=9.0,<10.0",
"mkdocstrings[python]>=0.24,<2.0",
]
server = [
"fastapi>=0.100.0,<1.0",
"uvicorn[standard]>=0.20.0,<1.0",
]
watch = [
"watchdog>=3.0,<7.0",
]
aws = ["boto3>=1.26.0,<2.0"]
gcp = ["google-cloud-aiplatform>=1.38.0,<2.0"]
azure = ["azure-ai-ml>=1.11.0,<2.0", "azure-identity>=1.12.0,<2.0"]
cloud-live = ["ai-bom[aws,gcp,azure]"]
enrich = ["litellm>=1.40.0,<3.0"]
callable = [] # base callable module — no SDKs required
callable-openai = ["openai>=1.0.0,<3.0"]
callable-anthropic = ["anthropic>=0.30.0,<2.0"]
callable-google = ["google-generativeai>=0.5.0,<2.0"]
callable-bedrock = ["boto3>=1.26.0,<2.0"]
callable-ollama = ["ollama>=0.3.0,<2.0"]
callable-mistral = ["mistralai>=1.0.0,<3.0"]
callable-cohere = ["cohere>=5.0.0,<7.0"]
callable-all = [
"ai-bom[callable-openai,callable-anthropic,callable-google,callable-bedrock,callable-ollama,callable-mistral,callable-cohere]",
]
all = ["ai-bom[dashboard,docs,server,watch,cloud-live,callable-all,enrich]"]
[project.scripts]
ai-bom = "ai_bom.cli:app"
[project.urls]
Homepage = "https://trusera.dev"
Documentation = "https://trusera.github.io/ai-bom/"
Repository = "https://github.com/trusera/ai-bom"
Issues = "https://github.com/trusera/ai-bom/issues"
Changelog = "https://github.com/trusera/ai-bom/blob/main/CHANGELOG.md"
[tool.hatch.version]
path = "src/ai_bom/__init__.py"
[tool.hatch.build.targets.sdist]
exclude = [
".venv",
".git",
".pytest_cache",
".ruff_cache",
".github",
"tests",
"htmlcov",
".coverage",
"demo-video",
"node_modules",
"*.mp4",
"*.gif",
"assets",
"docs",
]
[tool.hatch.build.targets.wheel]
packages = ["src/ai_bom"]
[tool.pytest.ini_options]
testpaths = ["tests"]
pythonpath = ["src"]
markers = [
"slow: marks tests as slow (deselect with '-m \"not slow\"')",
]
[tool.ruff]
target-version = "py310"
line-length = 100
[tool.ruff.lint]
select = ["E", "F", "I", "W", "S", "B", "C4", "UP", "SIM", "N", "RUF"]
ignore = [
"S101", # assert used in tests (pytest)
"S603", # subprocess call - check for untrusted input (we validate)
"S607", # start process with partial path
"UP007", # Use X | Y for union types (breaks Typer runtime introspection)
"UP045", # Use X | None (breaks Typer runtime introspection)
"RUF012", # mutable class default — valid for Pydantic models
"S112", # try-except-continue — valid pattern in file-scanning loops
"S110", # try-except-pass — reviewed, used in graceful fallbacks
]
[tool.ruff.lint.per-file-ignores]
"src/ai_bom/dashboard/frontend.py" = ["E501"]
"src/ai_bom/dashboard/*.py" = ["S104"] # bind 0.0.0.0 — intended for server
"tests/**/*.py" = ["S101", "S106", "S108", "N802", "N803"]
[tool.mypy]
python_version = "3.10"
warn_return_any = true
warn_unused_configs = true
disallow_untyped_defs = true
check_untyped_defs = true
ignore_missing_imports = true
namespace_packages = false
exclude = ["tests/", "docs/", "demo_data/"]
[tool.coverage.run]
source = ["ai_bom"]
omit = [
"*/dashboard/*",
"*/demo_data/*",
"*/server.py", # FastAPI server — requires uvicorn at runtime
"*/watcher.py", # Watchdog file watcher — requires watchdog at runtime
]
[tool.coverage.report]
fail_under = 80
show_missing = true
skip_empty = true