MERGE OPERATIONS: - Merged /opt/aitbc/cli/docs into /opt/aitbc/docs/cli - Eliminated duplicate CLI documentation locations - Created single source of truth for CLI docs ORGANIZATION IMPROVEMENTS: - Created structured subdirectories: • implementation/ - Core implementation summaries • analysis/ - Analysis reports and integration summaries • guides/ - Installation and setup guides • legacy/ - Historical documentation (archived) - Updated main README.md with: • New consolidated structure overview • Updated installation instructions for flat CLI structure • Recent CLI design principles changes • Proper navigation to subdirectories - Created legacy/README.md with: • Clear deprecation notice • File categorization • Purge candidates identification • Migration notes from old to new structure FILE MOVES: - 15 implementation summaries → implementation/ - 5 analysis reports → analysis/ - 3 setup guides → guides/ - 19 legacy documented files → legacy/ - 1 demonstration file → root (active reference) PROJECT DOCUMENTATION UPDATES: - Updated /docs/beginner/02_project/1_files.md - Reflected flattened CLI structure (cli/commands/ vs cli/aitbc_cli/commands/) - Added docs/cli/ as consolidated documentation location - Updated Python version requirement to 3.13.5 only BENEFITS: - Single location for all CLI documentation - Clear separation of current vs legacy information - Better organization and discoverability - Easier maintenance and updates - Proper archival of historical documentation STATUS: ✅ Consolidation complete ✅ Legacy properly archived ✅ Structure organized ✅ Documentation updated
4.4 KiB
4.4 KiB
AITBC CLI Local Package Installation
This directory contains the locally built AITBC CLI package for installation without PyPI access.
Quick Installation
Method 1: Automated Installation (Recommended)
# Run the installation script
./install_local_package.sh
Method 2: Manual Installation
# Create virtual environment
python3.13 -m venv venv
source venv/bin/activate
# Install from wheel file
pip install dist/aitbc_cli-0.1.0-py3-none-any.whl
# Verify installation
aitbc --version
Method 3: Direct Installation
# Install directly from current directory
pip install .
# Or from wheel file
pip install dist/aitbc_cli-0.1.0-py3-none-any.whl
Package Files
dist/aitbc_cli-0.1.0-py3-none-any.whl- Wheel package (recommended)dist/aitbc_cli-0.1.0.tar.gz- Source distributioninstall_local_package.sh- Automated installation scriptsetup.py- Package setup configurationrequirements.txt- Package dependencies
Requirements
- Python 3.13+ (strict requirement)
- 10MB+ free disk space
- Internet connection for dependency installation (first time only)
Usage
After installation:
# Activate the CLI environment (if using script)
source ./activate_aitbc_cli.sh
# Or activate virtual environment manually
source venv/bin/activate
# Check CLI version
aitbc --version
# Show help
aitbc --help
# Example commands
aitbc wallet balance
aitbc blockchain sync-status
aitbc marketplace gpu list
Configuration
# Set API key
export CLIENT_API_KEY=your_api_key_here
# Or save permanently
aitbc config set api_key your_api_key_here
# Set coordinator URL
aitbc config set coordinator_url http://localhost:8000
# Show configuration
aitbc config show
Troubleshooting
Python Version Issues
# Check Python version
python3 --version
# Install Python 3.13 (Ubuntu/Debian)
sudo apt update
sudo apt install python3.13 python3.13-venv
Permission Issues
# Use user installation
pip install --user dist/aitbc_cli-0.1.0-py3-none-any.whl
# Or use virtual environment (recommended)
python3.13 -m venv venv
source venv/bin/activate
pip install dist/aitbc_cli-0.1.0-py3-none-any.whl
Module Not Found
# Ensure virtual environment is activated
source venv/bin/activate
# Check installation
pip list | grep aitbc-cli
# Reinstall if needed
pip install --force-reinstall dist/aitbc_cli-0.1.0-py3-none-any.whl
Package Distribution
For Other Systems
-
Copy the package files:
# Copy wheel file to target system scp dist/aitbc_cli-0.1.0-py3-none-any.whl user@target:/tmp/ -
Install on target system:
# On target system cd /tmp python3.13 -m venv aitbc_env source aitbc_env/bin/activate pip install aitbc_cli-0.1.0-py3-none-any.whl
Local PyPI Server (Optional)
# Install local PyPI server
pip install pypiserver
# Create package directory
mkdir -p ~/local_pypi/packages
cp dist/*.whl ~/local_pypi/packages/
# Start server
pypiserver ~/local_pypi/packages -p 8080
# Install from local PyPI
pip install --index-url http://localhost:8080/simple/ aitbc-cli
Development
Building from Source
# Clone repository
git clone https://github.com/aitbc/aitbc.git
cd aitbc/cli
# Create virtual environment
python3.13 -m venv venv
source venv/bin/activate
# Install build tools
pip install build
# Build package
python -m build --wheel
# Install locally
pip install dist/aitbc_cli-0.1.0-py3-none-any.whl
Testing Installation
# Test basic functionality
aitbc --version
aitbc --help
# Test with mock data
aitbc wallet balance
aitbc blockchain sync-status
aitbc marketplace gpu list
Uninstallation
# Uninstall package
pip uninstall aitbc-cli
# Remove virtual environment
rm -rf venv
# Remove configuration (optional)
rm -rf ~/.aitbc/
Support
- Documentation: See CLI help with
aitbc --help - Issues: Report to AITBC development team
- Dependencies: All requirements in
requirements.txt
Package Information
- Name: aitbc-cli
- Version: 0.1.0
- Python Required: 3.13+
- Dependencies: 12 core packages
- Size: ~130KB (wheel)
- Entry Point:
aitbc=aitbc_cli.main:main
Features Included
- 40+ CLI commands
- Rich terminal output
- Multiple output formats (table, JSON, YAML)
- Secure credential management
- Shell completion support
- Comprehensive error handling
- Mock data for testing