diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 0000000..2d8e5b5 --- /dev/null +++ b/.editorconfig @@ -0,0 +1,18 @@ +root = true + +[*] +charset = utf-8 +end_of_line = lf +insert_final_newline = true +indent_style = space +indent_size = 2 +trim_trailing_whitespace = true + +[*.py] +indent_size = 4 + +[*.md] +trim_trailing_whitespace = false + +[Makefile] +indent_style = tab diff --git a/.github/labeler.yml b/.github/labeler.yml new file mode 100644 index 0000000..1b17e93 --- /dev/null +++ b/.github/labeler.yml @@ -0,0 +1,77 @@ +area/docs: + - changed-files: + - any-glob-to-any-file: + - "**/*.md" + - "**/*.mdx" + - "docs/**" + +area/frontend: + - changed-files: + - any-glob-to-any-file: + - "app/**" + - "components/**" + - "pages/**" + - "styles/**" + - "public/**" + +area/backend: + - changed-files: + - any-glob-to-any-file: + - "app/**" + - "api/**" + - "server/**" + - "src/**" + - "main.py" + +area/infra: + - changed-files: + - any-glob-to-any-file: + - "docker-compose*.yml" + - "**/Dockerfile*" + - "infra/**" + - "k8s/**" + - "helm/**" + - "**/*.tf" + +area/sdk: + - changed-files: + - any-glob-to-any-file: + - "governs_ai/**" + - "src/**" + - "pyproject.toml" + - "package.json" + - "tsconfig.json" + +area/security: + - changed-files: + - any-glob-to-any-file: + - "**/auth/**" + - "**/security/**" + - "manifest.json" + - "**/*policy*" + - "**/*permission*" + +kind/ci: + - changed-files: + - any-glob-to-any-file: + - ".github/workflows/**" + - ".github/labeler.yml" + +kind/tests: + - changed-files: + - any-glob-to-any-file: + - "tests/**" + - "**/*test*.py" + - "**/*.spec.ts" + - "**/*.test.ts" + - "**/*.test.tsx" + +kind/deps: + - changed-files: + - any-glob-to-any-file: + - "package.json" + - "pnpm-lock.yaml" + - "requirements.txt" + - "requirements-dev.txt" + - "pyproject.toml" + - "poetry.lock" diff --git a/.github/workflows/labeler.yml b/.github/workflows/labeler.yml new file mode 100644 index 0000000..36a6ceb --- /dev/null +++ b/.github/workflows/labeler.yml @@ -0,0 +1,19 @@ +name: PR Labeler + +on: + pull_request_target: + types: [opened, synchronize, reopened, ready_for_review] + +jobs: + label: + runs-on: ubuntu-latest + permissions: + contents: read + pull-requests: write + + steps: + - name: Label pull requests + uses: actions/labeler@v5 + with: + repo-token: "${{ secrets.GITHUB_TOKEN }}" + sync-labels: true diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 0000000..14e1503 --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,21 @@ +# Contributing to GovernsAI Python SDK + +## Setup + +```bash +python -m venv .venv +source .venv/bin/activate +pip install -e .[dev] +``` + +## Validation + +```bash +pytest +``` + +## Pull Request Checklist + +- Preserve API compatibility unless versioned. +- Add tests for new clients or transport behavior. +- Update README and SDK docs for public API changes. diff --git a/README.md b/README.md index 43ff07f..4a13cc7 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,9 @@ # GovernsAI Python SDK +[![npm](https://img.shields.io/npm/v/%40governs-ai%2Fsdk?label=npm%20%40governs-ai%2Fsdk)](https://www.npmjs.com/package/@governs-ai/sdk) +[![PyPI](https://img.shields.io/pypi/v/governs-ai-sdk?label=PyPI%20governs-ai-sdk)](https://pypi.org/project/governs-ai-sdk/) +[![License](https://img.shields.io/badge/license-MIT-green.svg)](LICENSE) + A comprehensive Python SDK for integrating AI governance capabilities into your applications. Provides secure control over AI interactions, budget management, policy enforcement, and compliance monitoring. ## Features