Initial memory skill - agent memory with pgvector semantic search

This commit is contained in:
Azat
2026-02-02 23:48:37 +01:00
commit bf5ba832ee
4 changed files with 744 additions and 0 deletions

22
scripts/run.sh Normal file
View File

@@ -0,0 +1,22 @@
#!/bin/bash
set -e
MEMORY_PORT="${MEMORY_PORT:-8081}"
SKILL_DIR="$(dirname "$(dirname "$0")")"
VENV_DIR="$SKILL_DIR/.venv"
# Source postgres connection
[ -f /run/vibestack/postgres.env ] && source /run/vibestack/postgres.env
# Export for Python
export MEMORY_PORT
export MEMORY_MODEL="${MEMORY_MODEL:-all-MiniLM-L6-v2}"
export MEMORY_RETENTION_DAYS="${MEMORY_RETENTION_DAYS:-30}"
export MEMORY_MAX_RESULTS="${MEMORY_MAX_RESULTS:-10}"
export DATABASE_URL="${DATABASE_URL:-postgresql://vibestack:vibestack@localhost:5432/vibestack}"
echo "Starting Memory API on port $MEMORY_PORT..."
echo "Model: $MEMORY_MODEL"
echo "Retention: ${MEMORY_RETENTION_DAYS} days"
exec "$VENV_DIR/bin/python" "$SKILL_DIR/src/api.py"