Skip to content

Commit

Permalink
- Busy bar index bug **fixed** - *(Console)*
Browse files Browse the repository at this point in the history
- Other minor fixed.
- Version count increase - v0.0.3
  • Loading branch information
Simatwa committed Dec 31, 2023
1 parent c547d58 commit 11aa3f7
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 10 deletions.
8 changes: 7 additions & 1 deletion docs/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,10 @@
- Enhanced response generation
- Prompt optimizers added - *[code, shell_command]*
- Prompt optimizers added - *Console*
- Clear console - *Console*
- Clear console - *Console*

## v0.0.3

**What's new?**
- Busy bar index bug **fixed** - *(Console)*
- Other minor fixed.
10 changes: 5 additions & 5 deletions docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<a href="https://github.com/Simatwa/tgpt2/actions/workflows/python-test.yml"><img src="https://github.com/Simatwa/tgpt2/actions/workflows/python-test.yml/badge.svg" alt="Python Test"/></a>
-->
<a href="LICENSE"><img alt="License" src="https://img.shields.io/static/v1?logo=GPL&color=Blue&message=MIT&label=License"/></a>
<a href="https://pypi.org/project/tgpt2"><img alt="PyPi" src="https://img.shields.io/static/v1?logo=pypi&label=Pypi&message=v0.0.2&color=green"/></a>
<a href="https://pypi.org/project/tgpt2"><img alt="PyPi" src="https://img.shields.io/static/v1?logo=pypi&label=Pypi&message=v0.0.3&color=green"/></a>
<a href="https://github.com/psf/black"><img alt="Black" src="https://img.shields.io/static/v1?logo=Black&label=Code-style&message=Black"/></a>
<a href="#"><img alt="Passing" src="https://img.shields.io/static/v1?logo=Docs&label=Docs&message=Passing&color=green"/></a>
<a href="https://github.com/Simatwa/tgpt2/actions/workflows/python-package.yml"><img src="https://github.com/Simatwa/tgpt2/actions/workflows/python-package.yml/badge.svg"/></a>
Expand Down Expand Up @@ -139,13 +139,13 @@ for value in resp:
print(value)
# Output
"""
{'completion': "I'm so", 'stop_reason': None, 'truncated': False, 'stop': None, 'model': 'llama-2-13b-chat', 'log_id': 'cmpl-3NmRt5A5Djqo2jXtXLBwJ2', 'exception': None}
{'completion': "I'm so", 'stop_reason': None, 'truncated': False, 'stop': None, 'model': 'llama-2-13b-chat', 'log_id': 'cmpl-3NmRt5A5Djqo2jXtXLBwxx', 'exception': None}
{'completion': "I'm so excited to share with.", 'stop_reason': None, 'truncated': False, 'stop': None, 'model': 'llama-2-13b-chat', 'log_id': 'cmpl-3NmRt5A5Djqo2jXtXLBwJ2', 'exception': None}
{'completion': "I'm so excited to share with.", 'stop_reason': None, 'truncated': False, 'stop': None, 'model': 'llama-2-13b-chat', 'log_id': 'cmpl-3NmRt5A5Djqo2jXtXLBwxx', 'exception': None}
{'completion': "I'm so excited to share with you the incredible ", 'stop_reason': None, 'truncated': False, 'stop': None, 'model': 'llama-2-13b-chat', 'log_id': 'cmpl-3NmRt5A5Djqo2jXtXLBwJ2', 'exception': None}
{'completion': "I'm so excited to share with you the incredible ", 'stop_reason': None, 'truncated': False, 'stop': None, 'model': 'llama-2-13b-chat', 'log_id': 'cmpl-3NmRt5A5Djqo2jXtXLBwxx', 'exception': None}
{'completion': "I'm so excited to share with you the incredible experiences...", 'stop_reason': None, 'truncated': False, 'stop': None, 'model': 'llama-2-13b-chat', 'log_id': 'cmpl-3NmRt5A5Djqo2jXtXLBwJ2', 'exception': None}
{'completion': "I'm so excited to share with you the incredible experiences...", 'stop_reason': None, 'truncated': False, 'stop': None, 'model': 'llama-2-13b-chat', 'log_id': 'cmpl-3NmRt5A5Djqo2jXtXLBwxx', 'exception': None}
"""
```

Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

setup(
name="tgpt2",
version="0.0.2",
version="0.0.3",
license="MIT",
author="Smartwa",
maintainer="Smartwa",
Expand Down
2 changes: 1 addition & 1 deletion tgpt2/__init__.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from .tgpt2 import TGPT
from .imager import Imager

__version__ = "0.0.2"
__version__ = "0.0.3"
__author__ = "Smartwa"
__repo__ = "https://github.com/Simatwa/tgpt2"

Expand Down
5 changes: 3 additions & 2 deletions tgpt2/console.py
Original file line number Diff line number Diff line change
Expand Up @@ -215,6 +215,7 @@ def do_settings(self, line):
self.prettify = click.confirm(
"\nPrettify markdown response", default=self.prettify
)
busy_bar.spin_index = click.prompt('Spin bar index [0:/, 1:■█■■■, 2:⣻]', default=busy_bar.spin_index,type=click.IntRange(0,2))
self.color = click.prompt("Response stdout font color", default=self.color)

@busy_bar.run(help="System error")
Expand Down Expand Up @@ -450,7 +451,7 @@ def interactive(
):
"""Chat with AI interactively"""
bot = Main(max_tokens, temperature, top_k, top_p, model, brave_key, timeout)
busy_bar.index = busy_bar_index
busy_bar.spin_index = busy_bar_index
bot.code_theme = code_theme
bot.color = color
bot.prettify = prettify
Expand Down Expand Up @@ -542,7 +543,7 @@ def generate(
):
"""Generate a quick response with AI"""
bot = Main(max_tokens, temperature, top_k, top_p, model, brave_key, timeout)
busy_bar.index = busy_bar_index
busy_bar.spin_index = busy_bar_index
bot.code_theme = code_theme
bot.color = color
bot.prettify = prettify
Expand Down

0 comments on commit 11aa3f7

Please sign in to comment.