Skip to content

Commit

Permalink
Merge pull request #39 from rhatdan/pragmatic
Browse files Browse the repository at this point in the history
convert main.py into installable CLI tool pragmatic
  • Loading branch information
ilya-kolchinsky authored Feb 7, 2025
2 parents c933c94 + 2ac1103 commit 4ed57a9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
5 changes: 3 additions & 2 deletions pragmatic/main.py → bin/pragmatic
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
# !/bin/python3
# addressing the issue where the project structure causes pragmatic to not be on the path
import sys
import os
sys.path.insert(0, os.path.abspath(os.getcwd()))

import argparse

from api import index_path_for_rag, execute_rag_query, evaluate_rag_pipeline
from settings import DEFAULT_SETTINGS
from pragmatic.api import index_path_for_rag, execute_rag_query, evaluate_rag_pipeline
from pragmatic.settings import DEFAULT_SETTINGS


def main():
Expand Down
1 change: 1 addition & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,5 @@
long_description=open('README.md').read(),
long_description_content_type='text/markdown',
url='https://github.com/redhat-et/PRAGmatic'
scripts=["bin/pragmatic"],
)

0 comments on commit 4ed57a9

Please sign in to comment.