llm-schema-lite 0.1.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,9 @@
1
+ coverage:
2
+ status:
3
+ project:
4
+ default:
5
+ target: 80%
6
+ threshold: 2%
7
+ patch:
8
+ default:
9
+ target: 80%
@@ -0,0 +1,15 @@
1
+ root = true
2
+
3
+ [*]
4
+ charset = utf-8
5
+ end_of_line = lf
6
+ insert_final_newline = true
7
+ trim_trailing_whitespace = true
8
+
9
+ [*.py]
10
+ indent_style = space
11
+ indent_size = 4
12
+
13
+ [*.{yml,yaml,toml}]
14
+ indent_style = space
15
+ indent_size = 2
@@ -0,0 +1,23 @@
1
+ ---
2
+ name: Bug Report
3
+ about: Report a bug in schema-lite
4
+ title: '[BUG] '
5
+ labels: bug
6
+ ---
7
+
8
+ ## Describe the bug
9
+ A clear description of what the bug is.
10
+
11
+ ## To Reproduce
12
+ ```python
13
+ # Minimal code to reproduce
14
+ ```
15
+
16
+ ## Expected behavior
17
+ What you expected to happen.
18
+
19
+ ## Environment
20
+ - schema-lite version:
21
+ - Python version:
22
+ - Pydantic version:
23
+ - OS:
@@ -0,0 +1,18 @@
1
+ ## Description
2
+ <!-- Describe your changes -->
3
+
4
+ ## Type of Change
5
+ - [ ] Bug fix
6
+ - [ ] New feature
7
+ - [ ] Breaking change
8
+ - [ ] Documentation update
9
+
10
+ ## Checklist
11
+ - [ ] Tests pass locally
12
+ - [ ] Added/updated tests
13
+ - [ ] Updated documentation
14
+ - [ ] Follows code style (ruff, mypy)
15
+ - [ ] Conventional commit messages
16
+
17
+ ## Related Issues
18
+ Closes #
@@ -0,0 +1,7 @@
1
+ version: 2
2
+ updates:
3
+ - package-ecosystem: "pip"
4
+ directory: "/"
5
+ schedule:
6
+ interval: "weekly"
7
+ open-pull-requests-limit: 10
@@ -0,0 +1,47 @@
1
+ name: CI
2
+
3
+ on:
4
+ push:
5
+ branches: [main, develop]
6
+ pull_request:
7
+ branches: [main]
8
+
9
+ jobs:
10
+ test:
11
+ runs-on: ubuntu-latest
12
+ strategy:
13
+ matrix:
14
+ python-version: ["3.10", "3.11", "3.12", "3.13"]
15
+
16
+ steps:
17
+ - uses: actions/checkout@v4
18
+ - name: Install uv
19
+ uses: astral-sh/setup-uv@v4
20
+ - name: Set up Python ${{ matrix.python-version }}
21
+ run: uv python install ${{ matrix.python-version }}
22
+ - name: Install dependencies
23
+ run: uv sync --all-extras
24
+ - name: Run tests
25
+ run: uv run pytest
26
+ - name: Upload coverage
27
+ uses: codecov/codecov-action@v4
28
+ if: matrix.python-version == '3.12'
29
+ with:
30
+ file: ./coverage.xml
31
+
32
+ lint:
33
+ runs-on: ubuntu-latest
34
+ steps:
35
+ - uses: actions/checkout@v4
36
+ - name: Install uv
37
+ uses: astral-sh/setup-uv@v4
38
+ - name: Set up Python
39
+ run: uv python install 3.12
40
+ - name: Install dependencies
41
+ run: uv sync --all-extras
42
+ - name: Run ruff
43
+ run: uv run ruff check src tests
44
+ - name: Run mypy
45
+ run: uv run mypy src
46
+ - name: Run bandit
47
+ run: uv run bandit -c pyproject.toml -r src
@@ -0,0 +1,19 @@
1
+ name: Publish to PyPI
2
+
3
+ on:
4
+ release:
5
+ types: [published]
6
+
7
+ jobs:
8
+ publish:
9
+ runs-on: ubuntu-latest
10
+ permissions:
11
+ id-token: write # Required for trusted publishing
12
+ steps:
13
+ - uses: actions/checkout@v4
14
+ - name: Install uv
15
+ uses: astral-sh/setup-uv@v4
16
+ - name: Build package
17
+ run: uv build
18
+ - name: Publish to PyPI
19
+ uses: pypa/gh-action-pypi-publish@release/v1
@@ -0,0 +1,152 @@
1
+ # Byte-compiled / optimized / DLL files
2
+ __pycache__/
3
+ *.py[cod]
4
+ *$py.class
5
+
6
+ # C extensions
7
+ *.so
8
+
9
+ # Distribution / packaging
10
+ .Python
11
+ build/
12
+ develop-eggs/
13
+ dist/
14
+ downloads/
15
+ eggs/
16
+ .eggs/
17
+ lib/
18
+ lib64/
19
+ parts/
20
+ sdist/
21
+ var/
22
+ wheels/
23
+ share/python-wheels/
24
+ *.egg-info/
25
+ .installed.cfg
26
+ *.egg
27
+ MANIFEST
28
+
29
+ # PyInstaller
30
+ *.manifest
31
+ *.spec
32
+
33
+ # Installer logs
34
+ pip-log.txt
35
+ pip-delete-this-directory.txt
36
+
37
+ # Unit test / coverage reports
38
+ htmlcov/
39
+ .tox/
40
+ .nox/
41
+ .coverage
42
+ .coverage.*
43
+ .cache
44
+ nosetests.xml
45
+ coverage.xml
46
+ *.cover
47
+ *.py,cover
48
+ .hypothesis/
49
+ .pytest_cache/
50
+ cover/
51
+ .pytest_cache/
52
+ *.log
53
+
54
+ # Translations
55
+ *.mo
56
+ *.pot
57
+
58
+ # Django stuff:
59
+ *.log
60
+ local_settings.py
61
+ db.sqlite3
62
+ db.sqlite3-journal
63
+
64
+ # Flask stuff:
65
+ instance/
66
+ .webassets-cache
67
+
68
+ # Scrapy stuff:
69
+ .scrapy
70
+
71
+ # Sphinx documentation
72
+ docs/_build/
73
+
74
+ # PyBuilder
75
+ .pybuilder/
76
+ target/
77
+
78
+ # Jupyter Notebook
79
+ .ipynb_checkpoints
80
+
81
+ # IPython
82
+ profile_default/
83
+ ipython_config.py
84
+
85
+ # pyenv
86
+ .python-version
87
+
88
+ # pipenv
89
+ Pipfile.lock
90
+
91
+ # poetry
92
+ poetry.lock
93
+
94
+ # pdm
95
+ .pdm.toml
96
+
97
+ # PEP 582
98
+ __pypackages__/
99
+
100
+ # Celery stuff
101
+ celerybeat-schedule
102
+ celerybeat.pid
103
+
104
+ # SageMath parsed files
105
+ *.sage.py
106
+
107
+ # Environments
108
+ .env
109
+ .venv
110
+ env/
111
+ venv/
112
+ ENV/
113
+ env.bak/
114
+ venv.bak/
115
+
116
+ # Spyder project settings
117
+ .spyderproject
118
+ .spyproject
119
+
120
+ # Rope project settings
121
+ .ropeproject
122
+
123
+ # mkdocs documentation
124
+ /site
125
+
126
+ # mypy
127
+ .mypy_cache/
128
+ .dmypy.json
129
+ dmypy.json
130
+
131
+ # Pyre type checker
132
+ .pyre/
133
+
134
+ # pytype static type analyzer
135
+ .pytype/
136
+
137
+ # Cython debug symbols
138
+ cython_debug/
139
+
140
+ # IDEs
141
+ .vscode/
142
+ .idea/
143
+ *.swp
144
+ *.swo
145
+ *~
146
+
147
+ # OS
148
+ .DS_Store
149
+ Thumbs.db
150
+
151
+ # Ruff
152
+ .ruff_cache/
@@ -0,0 +1,51 @@
1
+ repos:
2
+ - repo: https://github.com/pre-commit/pre-commit-hooks
3
+ rev: v5.0.0
4
+ hooks:
5
+ - id: trailing-whitespace
6
+ - id: end-of-file-fixer
7
+ - id: check-yaml
8
+ - id: check-toml
9
+ - id: check-json
10
+ - id: check-added-large-files
11
+ args: ['--maxkb=1000']
12
+ - id: check-merge-conflict
13
+ - id: check-case-conflict
14
+ - id: detect-private-key
15
+
16
+ - repo: https://github.com/astral-sh/ruff-pre-commit
17
+ rev: v0.8.4
18
+ hooks:
19
+ - id: ruff
20
+ args: [ --fix ]
21
+ types_or: [ python, pyi ]
22
+ - id: ruff-format
23
+ types_or: [ python, pyi ]
24
+
25
+ - repo: https://github.com/pre-commit/mirrors-mypy
26
+ rev: v1.13.0
27
+ hooks:
28
+ - id: mypy
29
+ files: ^src/
30
+ additional_dependencies: [
31
+ pytest>=7.0.0,
32
+ ]
33
+ args: [--strict, --ignore-missing-imports]
34
+
35
+ - repo: https://github.com/PyCQA/bandit
36
+ rev: 1.7.10
37
+ hooks:
38
+ - id: bandit
39
+ args: ["-c", "pyproject.toml"]
40
+ additional_dependencies: ["bandit[toml]"]
41
+ exclude: ^tests/
42
+
43
+ - repo: https://github.com/jorisroovers/gitlint
44
+ rev: v0.19.1
45
+ hooks:
46
+ - id: gitlint
47
+
48
+ - repo: https://github.com/opensource-nepal/commitlint
49
+ rev: v1.2.0
50
+ hooks:
51
+ - id: commitlint
@@ -0,0 +1,14 @@
1
+ # Changelog
2
+
3
+ All notable changes to this project will be documented in this file.
4
+
5
+ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
6
+ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
+
8
+ ## [Unreleased]
9
+
10
+ ### Added
11
+ - Initial project structure
12
+ - Package configuration with uv support
13
+ - Pre-commit hooks for code quality
14
+ - Comprehensive development tooling
@@ -0,0 +1,15 @@
1
+ # Code of Conduct
2
+
3
+ ## Our Pledge
4
+
5
+ We pledge to make participation in our project a harassment-free experience for everyone.
6
+
7
+ ## Standards
8
+
9
+ - Be respectful and inclusive
10
+ - Accept constructive criticism
11
+ - Focus on what's best for the community
12
+
13
+ ## Enforcement
14
+
15
+ Instances of unacceptable behavior may be reported to rohit.garuda1992@gmail.com
@@ -0,0 +1,29 @@
1
+ # Contributing to schema-lite
2
+
3
+ ## Development Setup
4
+
5
+ 1. Fork and clone the repository
6
+ 2. Install dependencies: `make setup`
7
+ 3. Create a branch: `git checkout -b feature/my-feature`
8
+ 4. Make changes and add tests
9
+ 5. Run tests: `make test`
10
+ 6. Run linters: `make lint`
11
+ 7. Commit with conventional commits: `git commit -m "feat: add new feature"`
12
+ 8. Push and create PR
13
+
14
+ ## Commit Convention
15
+
16
+ - `feat:` - New features
17
+ - `fix:` - Bug fixes
18
+ - `docs:` - Documentation changes
19
+ - `test:` - Test changes
20
+ - `refactor:` - Code refactoring
21
+ - `perf:` - Performance improvements
22
+ - `chore:` - Maintenance tasks
23
+
24
+ ## Code Style
25
+
26
+ - Use `ruff format` for formatting
27
+ - Pass `ruff check` and `mypy` checks
28
+ - Add type hints to all functions
29
+ - Write tests for new features
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2025 Rohit Garud
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -0,0 +1,5 @@
1
+ include README.md
2
+ include LICENSE
3
+ include pyproject.toml
4
+ recursive-include src *.py
5
+ recursive-include tests *.py
@@ -0,0 +1,87 @@
1
+ .PHONY: help install sync install-dev install-pre-commit pre-commit-run
2
+ .PHONY: test test-cov test-parallel test-fast test-slow
3
+ .PHONY: lint check format clean build changelog
4
+ .PHONY: publish-test publish update venv setup
5
+
6
+ help: ## Show this help message
7
+ @grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-20s\033[0m %s\n", $$1, $$2}'
8
+
9
+ # Installation
10
+ sync: ## Sync dependencies using uv
11
+ uv sync --all-extras
12
+
13
+ install: ## Install package
14
+ uv pip install -e .
15
+
16
+ install-dev: ## Install package with development dependencies
17
+ uv pip install -e ".[dev]"
18
+
19
+ install-pre-commit: ## Install pre-commit hooks
20
+ uv pip install pre-commit
21
+ pre-commit uninstall; pre-commit install; pre-commit install --hook-type commit-msg
22
+
23
+ # Testing
24
+ test: ## Run tests with pytest
25
+ pytest -rP -n auto --show-capture=no
26
+
27
+ test-cov: ## Run tests with coverage report
28
+ pytest --cov=schema_lite --cov-report=term-missing --cov-report=html
29
+
30
+ test-parallel: ## Run tests in parallel (alias for test)
31
+ pytest -rP -n auto
32
+
33
+ test-fast: ## Run tests excluding slow ones
34
+ pytest -m "not slow" -rP -n auto
35
+
36
+ test-slow: ## Run only slow tests
37
+ pytest -m slow -rP
38
+
39
+ # Code Quality
40
+ check: ## Quick health check (fast lint + type check)
41
+ ruff check src tests
42
+ mypy src --no-error-summary
43
+
44
+ lint: ## Run all linters (ruff, mypy, bandit)
45
+ ruff check src tests
46
+ mypy src
47
+ bandit -c pyproject.toml -r src
48
+
49
+ format: ## Format code with ruff
50
+ ruff format src tests
51
+ ruff check --fix src tests
52
+
53
+ pre-commit-run: ## Run pre-commit on all files
54
+ pre-commit run --all-files
55
+
56
+ # Maintenance
57
+ clean: ## Clean build artifacts and cache files
58
+ find . -type d -name '__pycache__' -exec rm -rf {} + 2>/dev/null || true
59
+ find . -type f -name "*.pyc" -delete
60
+ rm -rf build/ dist/ *.egg-info .pytest_cache .coverage htmlcov/ .mypy_cache .ruff_cache
61
+
62
+ # Building
63
+ build: ## Build package distribution
64
+ uv build
65
+
66
+ changelog: ## Generate changelog
67
+ git-changelog -o CHANGELOG.md
68
+
69
+ # Publishing
70
+ publish-test: ## Publish to Test PyPI
71
+ uv pip install twine
72
+ twine upload --repository-url https://test.pypi.org/legacy/ dist/*
73
+
74
+ publish: ## Publish to PyPI
75
+ uv pip install twine
76
+ twine upload dist/*
77
+
78
+ # Setup & Update
79
+ venv: ## Create virtual environment
80
+ uv venv
81
+
82
+ setup: venv install-dev install-pre-commit ## Complete setup for development
83
+ @echo "✓ Development environment setup complete!"
84
+ @echo "Activate the virtual environment with: source .venv/bin/activate"
85
+
86
+ update: clean sync install-pre-commit lint ## Full project update
87
+ @echo "✓ Project updated successfully!"