Build Conversational AI.
Project description
Chainlit for Amazon Brazil Build
Brazil-compatible version of Chainlit for Amazon's internal build system.
๐ Quick Start
Prerequisites
- Brazil build system access
uvinstalled (for virtual environment management)
Setup & Build
# 1. Navigate to project
cd /Volumes/workplace/Aki/src/Chainlit
# 2. Create proper virtual environment (CRITICAL for local builds)
uv venv .venv
# 3. Run Brazil build
brazil-build
Publish
-
make sure you update the version
-
run below command (temporarily use public PYPI, need to migrate to internal source)
uv publish build/* --token {PYPI_TOKEN}
โ Build Status
Production Ready - All issues resolved:
- โ Remote Brazil builds: Working
- โ Local Brazil builds: Working
- โ Python 3.10/3.11 compatibility: Fixed
- โ PeruPython integration: Complete
๐ Architecture
Polyglot Build System:
- Frontend: React/TypeScript (pnpm) โ Build assets
- Backend: Python package โ Integrate frontend assets
- Output:
amazon_chainlit-2.6.2-py3-none-any.whl(~12MB)
๐ Project Structure
Chainlit/
โโโ README.md # This guide
โโโ BRAZIL_BUILD_INTEGRATION.md # Troubleshooting FAQ
โโโ brazil.ion # Peru package config
โโโ .venv/ # Virtual environment (create with uv)
โโโ build-tools/bin/polyglot-build.sh # Main build script
โโโ third-party-src/
โ โโโ backend/ # Python source
โ โโโ frontend/ # React frontend
โ โโโ libs/ # React libraries
โโโ build/ # Build output
๐ง Development
Local Development Setup
# Virtual environment (required for local Brazil builds)
uv venv .venv
source .venv/bin/activate
# Install development dependencies
cd third-party-src
pnpm install
Build Commands
# Full build (local)
brazil-build
# Clean build
brazil-build clean
# Test individual components
cd third-party-src
pnpm build # Build all frontend components
Testing Your Changes
# 1. Local build test
brazil-build
# 2. Verify artifacts
ls -la build/
# Expected: amazon_chainlit-2.6.2-py3-none-any.whl (~12MB)
โ ๏ธ Critical Setup Requirements
1. Virtual Environment Setup
Must use uv venv .venv - not mkdir .venv
# โ
Correct
uv venv .venv
# โ Wrong - will fail
mkdir .venv
PeruPython expects proper activation scripts at .venv/bin/activate.
2. Build Dependencies
Automatically handled by brazil.ion:
- PeruPython (for virtual environment)
- PeruNPM (for frontend builds)
3. Build Process
- Frontend Build: React components with pnpm
- Backend Build: Python package with PeruPython
- Asset Integration: Frontend โ Python package
- Output: Wheel file in
build/
๐งช Verification
Successful Build Output:
=== Build completed successfully! ===
Artifacts available in: /path/to/build
BUILD SUCCEEDED
Expected Artifacts:
build/
โโโ amazon_chainlit-2.6.2-py3-none-any.whl (~12MB)
โโโ amazon_chainlit-2.6.2.tar.gz (~12MB)
๐ Troubleshooting
Having build issues? See BRAZIL_BUILD_INTEGRATION.md for:
- Complete troubleshooting FAQ
- Common error solutions
- Debug commands
- Environment fixes
Quick Fixes
Build failing locally?
# Fix virtual environment
rm -rf .venv
uv venv .venv
brazil-build
PeruPython issues?
# Check availability
which perupy-get-venv
# Should return: /path/to/PeruPython/bin/perupy-get-venv
๐ Additional Resources
- Troubleshooting FAQ - Fix build failures
- Original Chainlit - Upstream documentation
- Brazil Build System - Amazon internal docs
Ready to build! Run brazil-build and expect BUILD SUCCEEDED โ
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file chainlit_aki-2.9.0-py3-none-any.whl.
File metadata
- Download URL: chainlit_aki-2.9.0-py3-none-any.whl
- Upload date:
- Size: 9.8 MB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.8.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5c8b5b8623fb2bbf47f0dbfc3c5c6a58d3144f9eca1e848e02f3f4c183348950
|
|
| MD5 |
7ad6d87ccf767fcfc44fb7b203d3c49a
|
|
| BLAKE2b-256 |
f58fed2e50d076496dcf4b597bbf11e9e15fb613d7659ada42560ed40adb49db
|