Build a personalized Bitcoin (BTC) virtual assistant in Python with Hopsworks and LLM function call…

Learn to create a Python-based Bitcoin virtual assistant using Hopsworks and LLMs. Explore real-time price analysis, predictive modeling, and function calling for crypto insights.

Key takeaways
  • Built a Bitcoin virtual assistant using Hopsworks, Python, and LLM function calling that can analyze trends and make price predictions

  • System architecture follows FDI Pipeline with three components:

    • Feature pipeline: processes Bitcoin price data from Binance and Twitter APIs
    • Training pipeline: trains TensorFlow model for price predictions
    • Inference pipeline: handles model deployment and real-time predictions
  • Uses function calling to allow LLM to:

    • Retrieve historical price data
    • Make price predictions
    • Process user queries intelligently
  • Implements Retrieval Augmented Generation (RAG) to provide LLM with contextual data and real-time information beyond its training cutoff date

  • Uses OpenHermes 2.5 (Mistral-based) as the LLM, fine-tuned with ChatML format

  • Leverages Hopsworks for:

    • Feature store management
    • Model registry
    • Model serving capabilities
    • Feature group organization
  • Function calling proved reliable when properly structured with clear examples and instructions

  • System limitations include:

    • LLM can sometimes get confused with previous questions
    • Price predictions should not be considered financial advice
    • Market volatility makes predictions unreliable
  • Uses prompt engineering and templates to guide LLM responses and function selection

  • Integrates streaming pipeline for continuous data processing from Binance and Twitter