enh: current time fc

This commit is contained in:
Timothy J. Baek 2024-06-01 14:38:01 -07:00
parent a248b96dba
commit 871348049f

View File

@ -1,6 +1,9 @@
import os import os
import requests import requests
from typing import Literal, List, Optional from typing import Literal, List, Optional
from datetime import datetime
from blueprints.function_calling_blueprint import Pipeline as FunctionCallingBlueprint from blueprints.function_calling_blueprint import Pipeline as FunctionCallingBlueprint
@ -14,6 +17,19 @@ class Pipeline(FunctionCallingBlueprint):
def __init__(self, pipeline) -> None: def __init__(self, pipeline) -> None:
self.pipeline = pipeline self.pipeline = pipeline
def get_current_time(
self,
) -> str:
"""
Get the current time.
:return: The current time.
"""
now = datetime.now()
current_time = now.strftime("%H:%M:%S")
return f"Current Time = {current_time}"
def get_current_weather( def get_current_weather(
self, self,
location: str, location: str,