Skip to content

Commit

Permalink
included temp in project list
Browse files Browse the repository at this point in the history
  • Loading branch information
mehfuzh committed Aug 1, 2024
1 parent 42573be commit 711db72
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 8 deletions.
3 changes: 2 additions & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@ PyYAML==6.0.1
requests==2.32.3
typer==0.12.3
art==6.2
inquirer==3.3.0
inquirer==3.3.0
tabulate==0.9.0
5 changes: 3 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
'requests==2.32.3',
'typer==0.12.3',
'art==6.2',
'inquirer==3.3.0'
'inquirer==3.3.0',
'tabulate==0.9.0'
]

setup(
Expand All @@ -20,7 +21,7 @@
version=__version__,
author_email='mehfuz@smartloop.ai',
author='Smartloop Inc.',
url='https://github.com/SmartloopHQ/smartloop-cl',
url='https://github.com/SmartloopHQ/smartloop-cli',
keywords=['LLM', 'framework', 'llama3', 'phi3', 'platform'],
packages=find_packages(exclude=['tests*']),
py_modules=['main', 'constants'],
Expand Down
2 changes: 1 addition & 1 deletion smartloop/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,4 @@
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.

__version__="1.0.7"
__version__="1.0.8"
18 changes: 14 additions & 4 deletions smartloop/cmd/project.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@
import posixpath
import os
import re
import json

from tabulate import tabulate

import inquirer
from inquirer.themes import GreenPassion
Expand Down Expand Up @@ -59,11 +60,20 @@ def select() -> dict:
def list():
profile = UserProfile.load()
project = profile.get('project', None)

print_project = lambda x :tabulate(x, headers=['current','id', 'title', 'name', 'temp'])

projects = Projects(profile).get_all()
_ = [
console.print(f"{ '*' if project is not None and proj['id'] == project['id']else ' '} {proj['title']}({proj['name']})")

console.print(print_project([
['[*]' if project is not None and proj['id'] == project['id']else '[ ]',
proj['id'],
proj['title'],
proj['name'],
proj['config'].get('temparature', 0.3)
]
for proj in projects
]
]))


@app.command(short_help="Create a new project")
Expand Down

0 comments on commit 711db72

Please sign in to comment.