refactor: cleanup

This commit is contained in:
wea_ondara
2024-05-29 18:38:03 +02:00
parent d6ef6ea1dc
commit 2eb9e33947
3 changed files with 2 additions and 6 deletions

View File

@@ -51,10 +51,6 @@ class AiBase:
os.mkdir(path)
def __del__(self):
try:
raise Exception()
except Exception as e:
print(e)
del self.model
del self.tokenizer

View File

@@ -33,7 +33,6 @@ class Server:
if json_body['command'] == 'chat':
bot = self._server.get_bot(json_body['modelId'])
print(bot)
bot.ensure_loaded()
response = bot.generate(json_body['messages'],
token_count=json_body['tokenCount'],

View File

@@ -34,7 +34,8 @@ export default defineConfig({
'^/api/.*$': {
target: 'http://localhost:5172',
changeOrigin: true,
}, '^/ws/.*$': {
},
'^/ws/.*$': {
target: 'http://localhost:5172',
changeOrigin: true,
ws: true,