Skip to main content

Set up a modern LLM app by running one command

Project description

create-ragbits-app

A CLI tool to create new ragbits applications from templates.

Usage

# Create a new ragbits application
uvx create-ragbits-app

Available Templates

  • rag: Basic RAG (Retrieval Augmented Generation) application

Creating Custom Templates

Templates are stored in the templates/ directory. Each template consists of:

  1. A directory with the template name
  2. A template_config.py file with template metadata and questions
  3. Template files, with .j2 extension for files that should be processed as Jinja2 templates

Available variables in templates:

  • project_name: Name of the project
  • pkg_name: Name of the python package
  • ragbits_version: Latest version of ragbits
  • Custom variables from template questions

Template structure

To create a new template, add a directory under templates/ with:

  1. Template files (ending in .j2) - these will be rendered using Jinja2
  2. A template_config.py file with template metadata and questions

For example, see the templates/example-template directory.

Template Configuration

The template_config.py file should define a TemplateConfig class that inherits from TemplateConfig and creates a config instance at the bottom of the file:

from typing import List
from create_ragbits_app.template_config_base import (
    TemplateConfig,
    TextQuestion,
    ListQuestion,
    ConfirmQuestion
)

class ExampleTemplateConfig(TemplateConfig):
    name: str = "My Template Name"
    description: str = "Description of the template"

    questions: List = [
        TextQuestion(
            name="variable_name",
            message="Question to display to user",
            default="Default value"
        ),
        # More questions...
    ]

# Create instance of the config to be imported
config = ExampleTemplateConfig()

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

create_ragbits_app-0.1.0.tar.gz (36.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

create_ragbits_app-0.1.0-py3-none-any.whl (63.1 kB view details)

Uploaded Python 3

File details

Details for the file create_ragbits_app-0.1.0.tar.gz.

File metadata

  • Download URL: create_ragbits_app-0.1.0.tar.gz
  • Upload date:
  • Size: 36.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.13

File hashes

Hashes for create_ragbits_app-0.1.0.tar.gz
Algorithm Hash digest
SHA256 86bd825bc2326d76c9a6ad2479f666b0fca049d3d0560aaf74fe542cefd0baf2
MD5 f5d5e9ce0f3ce1209bf0780574701cd6
BLAKE2b-256 1940b6032da1439b7439d108684704eaf88118538b6b496fda170c8713e81be2

See more details on using hashes here.

File details

Details for the file create_ragbits_app-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for create_ragbits_app-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 27cabc5dd87a1374b291e88e46d774232be4f2aee8359beab9fc6efc1d8ca62f
MD5 91e3c10b42667f6722ecade123d96ebe
BLAKE2b-256 b745c5ef4e8f607b1669e0bd33ff784659d625637d2a2553d6b99a25fb89f078

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page