Skip to main content

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()

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.1.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.1-py3-none-any.whl (63.1 kB view details)

Uploaded Python 3

File details

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

File metadata

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

File hashes

Hashes for create_ragbits_app-0.1.1.tar.gz
Algorithm Hash digest
SHA256 f784f99fadb58f7ad4bb06dfc9c97c4d358ff254dfe6dbfa7dc56701472c58ec
MD5 3e0318e6f1916f93e6aa8ce97f4530af
BLAKE2b-256 cbbdbce41b40b3badc8e9fdce9ffbf47bb4745e91b1d5c5d0a7a2d3febf25ae7

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for create_ragbits_app-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 61d866273bd2cc272f553f5dbf2d75b958cf44a46696c384e5c45570257e622c
MD5 c1f72ce76c49055f14e785827e0e2e37
BLAKE2b-256 d6a050e5f19d3d41940674115880199e0967209a3d003d435b74d6ddcea39a83

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 files

0.1.0

2 files

0.0.12

2 files

0.0.11

2 files

0.0.10

2 files

0.0.9

2 files

0.0.8

2 files

0.0.7

2 files

0.0.6

2 files

0.0.5

2 files

0.0.4

2 files

0.0.3

2 files

0.0.2

2 files

0.0.1

2 files

Supported by

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