A natural language DSL compiler that generates polyglot serverless functions with integrated service support.
- Rust 1.77+ (for development)
- Podman Desktop or Podman CLI (for containerization)
- Kubernetes cluster (for deployment)
- kubectl (for cluster management)
- Build the container image:
./scripts/build-podman.sh- Run locally with Podman Compose:
# Copy environment template
cp .env.example .env
# Edit .env with your configuration
# Start all services
podman-compose up -d
# View logs
podman-compose logs -f talkpp-api- Access the services:
- Talk++ API: http://localhost:8080
- PgAdmin: http://localhost:8081 (admin@talkpp.dev / admin)
- PostgreSQL: localhost:5432
- Redis: localhost:6379
- Deploy to Kubernetes:
# Deploy everything
./scripts/deploy-k8s.sh
# Check deployment status
./scripts/deploy-k8s.sh status
# Run health check
./scripts/deploy-k8s.sh health
# Clean up deployment
./scripts/deploy-k8s.sh clean- Access the application:
With Ingress (recommended):
# Add to /etc/hosts
echo "127.0.0.1 talkpp.local api.talkpp.local" | sudo tee -a /etc/hosts
# Access via browser
open http://talkpp.localWith NodePort:
# Access directly via cluster IP
open http://localhost:30080With Port Forward:
kubectl port-forward service/talkpp-api 8080:8080 -n talkpp
open http://localhost:8080Write natural language workflows that compile to multiple target languages:
// Basic user registration workflow
if new user registers then
validate email using SendGrid
store user data in PostgreSQL
send welcome SMS using Twilio
// Advanced conditional logic
if payment received then
amount: payment.amount
if amount > 1000 then
send high_value_alert using SendGrid
create audit_log in PostgreSQL
else
send receipt using SendGrid
update inventory in PostgreSQL
send confirmation SMS using Twilio
# Compile to Rust
talkppc build -i workflow.tpp -o workflow.rs --target rust
# Compile to Python with optimization
talkppc build -i workflow.tpp --target python --optimization release
# Check syntax
talkppc check -i workflow.tpp
# Show supported languages
talkppc info# Simulate with mock services
talkpprun simulate -i workflow.rs --mock --event '{"user": "test@example.com"}'
# Execute with real services
talkpprun execute --function-id uuid --event '{"data": "value"}'
# List deployed functions
talkpprun list --detailedDSL Source β Lexer β Parser β AST β Code Generator β Target Code
(.tpp) β β β β (.rs/.py/.js/.ts/.sh)
Tokens Parse Abstract Rust/Python/JavaScript/TypeScript/Bash
Tree Syntax Function Generation
Tree
- π§ Compiler: DSL β Multi-language code generation
- β‘ Runtime: Async execution engine with Tokio
- π Auth: JWT-based authentication & authorization
- π Services: SendGrid, Twilio, PostgreSQL integrations
- π§ͺ Simulator: Dry-run testing with mock services
- π API: REST endpoints for function management
- π» CLI: Command-line tools for development workflow
graph TB
subgraph "Kubernetes Cluster"
subgraph "talkpp namespace"
API[Talk++ API Server]
PG[(PostgreSQL)]
RD[(Redis)]
API --> PG
API --> RD
end
subgraph "Ingress"
ING[Nginx Ingress]
ING --> API
end
end
subgraph "External Services"
SG[SendGrid]
TW[Twilio]
API --> SG
API --> TW
end
subgraph "Developer Machine"
PD[Podman Desktop]
K8S[kubectl]
PD -.-> API
K8S -.-> API
end
The project uses Podman-compatible Containerfiles for maximum compatibility:
- Multi-stage builds for optimized images
- Non-root user for security
- Alpine Linux base for minimal size
- Health checks for container orchestration
- Podman Desktop integration ready
- Namespace:
talkppwith resource quotas - Deployment: Talk++ API server with 2 replicas
- Services: ClusterIP, NodePort, and LoadBalancer options
- Ingress: Nginx-based routing with TLS support
- ConfigMaps: Application configuration
- Secrets: Sensitive data management
- PostgreSQL: Persistent database with initialization scripts
- Redis: Caching and session storage
- PVCs: Persistent storage for data
- Health checks: Liveness, readiness, and startup probes
- Resource limits: CPU and memory constraints
- Logging: Structured logs with tracing support
- Metrics: Prometheus-compatible endpoints
# 1. Set up environment
cp .env.example .env
# Edit .env with your configuration
# 2. Start services with Podman
podman-compose up -d
# 3. Run tests
cargo test
# 4. Build and test changes
./scripts/build-podman.sh# 1. Build container image
./scripts/build-podman.sh
# 2. Deploy to cluster
./scripts/deploy-k8s.sh
# 3. Monitor deployment
kubectl get pods -n talkpp -w
# 4. View logs
kubectl logs -f deployment/talkpp-api -n talkpp- Open Podman Desktop
- Import the built image (automatically available after build)
- Use the GUI to manage containers and volumes
- Monitor logs and metrics through the dashboard
POST /auth/login
POST /auth/register
POST /auth/refreshGET /functions # List functions
POST /functions # Create function
GET /functions/:id # Get function details
PUT /functions/:id # Update function
DELETE /functions/:id # Delete function
POST /functions/:id/exec # Execute functionGET /health # Health check
GET /ready # Readiness check
GET /metrics # Prometheus metricssend welcome_email using SendGrid
send password_reset using SendGrid with template "reset"
send verification_code using Twilio
send alert_message using Twilio with priority "high"
store user_data in PostgreSQL
query user_profiles from PostgreSQL where active=true
update inventory in PostgreSQL set quantity=new_quantity
cargo test # All tests
cargo test compiler:: # Compiler tests
cargo test --package runtime # Runtime testscargo test --test integration# Test container build and functionality
./scripts/build-podman.sh
# Test container deployment
podman run --rm localhost/talkpp:latest talkppc info# Deploy to test cluster
./scripts/deploy-k8s.sh
# Run health checks
./scripts/deploy-k8s.sh health
# Clean up
./scripts/deploy-k8s.sh cleanuse anyhow::Result;
use serde::{Deserialize, Serialize};
use tracing::info;
pub async fn handler(event: Event) -> Result<Response> {
info!("Processing user registration");
if event.data["action"] == "register" {
send_email_sendgrid(&event.data["email"], "Welcome!").await?;
store_postgresql("users", &event.data).await?;
send_sms_twilio(&event.data["phone"], "Welcome to our platform!").await?;
}
Ok(Response::success("Registration processed"))
}import asyncio
import logging
from typing import Dict, Any
async def handler(event: Dict[str, Any]) -> Dict[str, Any]:
logging.info("Processing user registration")
if event["data"]["action"] == "register":
await send_email_sendgrid(event["data"]["email"], "Welcome!")
await store_postgresql("users", event["data"])
await send_sms_twilio(event["data"]["phone"], "Welcome to our platform!")
return {"success": True, "message": "Registration processed"}- Podman Compose for local development
- Mock services enabled
- Debug logging active
- Hot reload with file watching
- Kubernetes cluster deployment
- Real services with test credentials
- Resource limits enforced
- Health monitoring active
- Kubernetes with Helm charts
- Production services with real credentials
- Horizontal Pod Autoscaling
- Full observability stack
- Non-root user (UID 1001)
- Minimal base image (Alpine Linux)
- No package managers in runtime image
- Security contexts in Kubernetes
- JWT authentication with secure secrets
- Input validation and sanitization
- Environment variable configuration
- Secrets management via Kubernetes secrets
- Ingress TLS termination
- Network policies for pod communication
- Service mesh ready (Istio compatible)
- Prometheus compatible metrics endpoint
- Custom metrics for compilation and execution
- Grafana dashboards for visualization
- Structured logging with
tracing - JSON output for log aggregation
- Request tracing with correlation IDs
- Liveness probes for container health
- Readiness probes for traffic routing
- Startup probes for slow-starting containers
- β DSL compiler with multi-language support
- β Basic service integrations
- β Podman containerization
- β Kubernetes deployment
- β CLI tools
- π Web UI for function management
- π Advanced DSL features (loops, functions)
- π More service integrations
- π Performance optimizations
- π² Visual DSL editor
- π² Function marketplace
- π² Advanced debugging tools
- π² Multi-tenant support
- Fork the repository
- Create a feature branch:
git checkout -b feature/amazing-feature - Make your changes and test thoroughly
- Build and test containers:
./scripts/build-podman.sh - Test Kubernetes deployment:
./scripts/deploy-k8s.sh - Commit your changes:
git commit -m 'Add amazing feature' - Push to the branch:
git push origin feature/amazing-feature - Open a Pull Request
# Clone and setup
git clone https://github.com/Diatonic-AI/TalkerAI.git
cd TalkerAI
# Install Rust toolchain
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
# Install Podman Desktop (Ubuntu)
flatpak install flathub io.podman_desktop.PodmanDesktop
# Setup local environment
cp .env.example .env
# Edit .env with your settings
# Start development services
podman-compose up -d
# Run tests
cargo testThis project is licensed under the MIT License - see the LICENSE file for details.
- Rust Community for excellent tooling and libraries
- Podman Project for secure containerization
- Kubernetes for orchestration capabilities
- Service Providers (SendGrid, Twilio) for integration APIs
- Issues: GitHub Issues
- Discussions: GitHub Discussions
- Documentation: Wiki
Talk++ - Making serverless functions as easy as natural language π