Skip to main content

Development tools and utilities for SAGE framework ecosystem

Project description

SAGE Dev Tools

Development tools and utilities for the SAGE framework ecosystem.

๐Ÿ“‹ Overview

sage-dev-tools provides a comprehensive suite of development utilities for SAGE framework maintainers and contributors. This repository consolidates development scripts, maintenance tools, and reporting utilities that were previously scattered across the SAGE monorepo.

๐ŸŽฏ Purpose

This repository serves as a central hub for:

  1. Work Report Generation - Automated weekly/monthly/quarterly/yearly reports
  2. Code Maintenance - Cluster sync, Git optimization, migration scripts
  3. Quality Assurance - Code quality checks and validation tools
  4. Documentation Tools - Doc validation and organization utilities
  5. Development Scripts - Various helper scripts for SAGE development

๐Ÿš€ Installation

From PyPI

# Basic installation
pip install isage-dev-tools

# With LLM support (for AI-powered work reports)
pip install isage-dev-tools[llm]

# Development installation
pip install isage-dev-tools[dev]

# Full installation
pip install isage-dev-tools[all]

From Source

git clone https://github.com/intellistream/sage-dev-tools.git
cd sage-dev-tools
pip install -e ".[dev]"

๐Ÿ“ฆ Features

๐Ÿ—‚๏ธ Work Report Generator

Generate comprehensive work reports with AI-powered summaries:

# Weekly report
sage-dev-tools report --period weekly

# Monthly report with AI summaries
sage-dev-tools report --period monthly --use-llm

# Custom date range
sage-dev-tools report --days 14 --output my_report.md

# Specific repositories
sage-dev-tools report --repos "SAGE,sage-examples,sagellm"

๐Ÿ”ง Maintenance Tools

# Sync code to cluster
sage-dev-tools maintenance sync-cluster --config cluster.yaml

# Optimize Git repository
sage-dev-tools maintenance optimize-git

# Migrate tutorials
sage-dev-tools maintenance migrate-tutorials --from SAGE --to sage-tutorials

โœ… Quality Tools

# Check code quality
sage-dev-tools quality check

# Validate documentation
sage-dev-tools docs validate

# Check architecture compliance
sage-dev-tools quality check-architecture

๐Ÿ› ๏ธ Utility Scripts

Located in scripts/ directory:

  • setup_workspace.sh - Set up development workspace
  • verify_compliance.sh - Verify architectural compliance
  • migrate_*.sh - Various migration scripts

๐Ÿ“– Usage

Work Report Generation

The work report generator analyzes Git history across SAGE repositories and generates comprehensive reports:

Features:

  • Multi-repository support (SAGE main + submodules)
  • Configurable time periods (weekly/monthly/quarterly/yearly)
  • AI-powered commit summaries (optional)
  • Multiple output formats (Markdown/JSON/Console)
  • Bilingual support (ไธญๆ–‡/English)

Configuration:

Create a .env file:

# GitHub Token (required for private repos)
GITHUB_TOKEN=ghp_xxx
GIT_TOKEN=ghp_xxx

# LLM Configuration (optional, for AI summaries)
SAGE_CHAT_API_KEY=sk-xxx
SAGE_CHAT_BASE_URL=https://api.openai.com/v1
SAGE_CHAT_MODEL=gpt-4

# HuggingFace (optional)
HF_TOKEN=hf_xxx

Example:

# Generate weekly report with AI summaries
sage-dev-tools report \
    --period weekly \
    --branch main-dev \
    --format markdown \
    --language zh \
    --use-llm \
    --output reports/weekly_report.md

Maintenance Operations

Sync code to remote cluster:

sage-dev-tools maintenance sync-cluster \
    --config config/cluster.yaml \
    --target node1,node2

Optimize Git repository:

sage-dev-tools maintenance optimize-git \
    --gc \
    --prune \
    --repack

๐Ÿ—๏ธ Architecture

sage-dev-tools/
โ”œโ”€โ”€ src/sage_dev_tools/
โ”‚   โ”œโ”€โ”€ cli/           # CLI commands (Click)
โ”‚   โ”œโ”€โ”€ work_report/   # Work report generator
โ”‚   โ”œโ”€โ”€ maintenance/   # Maintenance tools
โ”‚   โ”œโ”€โ”€ quality/       # Code quality tools
โ”‚   โ”œโ”€โ”€ docs/          # Documentation tools
โ”‚   โ””โ”€โ”€ utils/         # Shared utilities
โ”œโ”€โ”€ scripts/           # Standalone helper scripts
โ”œโ”€โ”€ tests/             # Test suite
โ””โ”€โ”€ docs/              # Documentation

๐Ÿ”— Relationship with SAGE Ecosystem

sage-tools (isage-tools)

  • Purpose: Framework-integrated development CLI
  • PyPI: isage-tools
  • Import: sage.tools
  • CLI: sage-dev
  • Scope: SAGE framework development (L5 layer)

sage-dev-tools (isage-dev-tools)

  • Purpose: Standalone development utilities
  • PyPI: isage-dev-tools
  • Import: sage_dev_tools
  • CLI: sage-dev-tools
  • Scope: Cross-repository maintenance and reporting

๐Ÿค Contributing

  1. Fork the repository
  2. Create a feature branch
  3. Make your changes
  4. Add tests
  5. Submit a pull request

See CONTRIBUTING.md for details.

๐Ÿ“ Migration Notes

This repository consolidates tools migrated from:

  • SAGE/tools/scripts/
  • SAGE/tools/maintenance/
  • SAGE/tools/lib/
  • Workflow-embedded utilities (work report generator)

Files that remain in SAGE main repo:

  • tools/install/ - Installation scripts
  • tools/hooks/ - Git hooks
  • tools/config/ - Project-specific configs

๐Ÿ“„ License

Apache License 2.0 - See LICENSE

๐Ÿ™‹ Support

๐ŸŽฏ Roadmap

  • Project structure setup
  • Work report generator implementation
  • Maintenance tools migration
  • Quality tools migration
  • Documentation tools
  • PyPI publication
  • SAGE workflow integration
  • Comprehensive test coverage

Part of the SAGE Framework Ecosystem - https://github.com/intellistream/SAGE

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

isage_dev_tools-0.1.0.0.tar.gz (33.8 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

isage_dev_tools-0.1.0.0-py3-none-any.whl (36.4 kB view details)

Uploaded Python 3

isage_dev_tools-0.1.0.0-py2.py3-none-any.whl (38.2 kB view details)

Uploaded Python 2Python 3

File details

Details for the file isage_dev_tools-0.1.0.0.tar.gz.

File metadata

  • Download URL: isage_dev_tools-0.1.0.0.tar.gz
  • Upload date:
  • Size: 33.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.11

File hashes

Hashes for isage_dev_tools-0.1.0.0.tar.gz
Algorithm Hash digest
SHA256 af1d20991e908dc08c371035ba0b03a8f5a4d1e4b51c3c7a036130399e0e53ba
MD5 bf51e69f939d49cbfb5c1d442fb405ad
BLAKE2b-256 6492eb63475005baa773dd310c11b2f1998aae88b291623a6996c35b4b877679

See more details on using hashes here.

File details

Details for the file isage_dev_tools-0.1.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for isage_dev_tools-0.1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 d7be8bea6d0f24c96655c7c2ba096a0a6d017756235d3712f25992d9e5d43c1d
MD5 88bb556600953ab43e3408a9a1df67b3
BLAKE2b-256 d659e41c829aaa6281ecbd9af61fd6d6cdca92aaec3593352cb20fe551070b1c

See more details on using hashes here.

File details

Details for the file isage_dev_tools-0.1.0.0-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for isage_dev_tools-0.1.0.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 ae81394f04ca860e44f16fe7fb6af28ecc4ad0e7f1864232aaba01cb58b4f2ef
MD5 214ffa3fbbf935113a5a6459aa56eeeb
BLAKE2b-256 1a82e673fc3302b5f168ca51af3d97b687187b1f1fc16da7c537a0de3eb63b09

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page