This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from autogen import AssistantAgent, UserProxyAgent, config_list_from_json | |
config_list_paid = [ | |
{ | |
"model": "gpt-4-1106-preview", | |
"api_key": "YOUR-KEY" | |
} | |
] | |
config_list_free = [ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# A skill to store markdown content to our second brain obsidian | |
import os | |
def store_note_to_obsidian(filename, content): | |
""" | |
Store markdown content to our second brain in a local Obsidian vault | |
:param filename: str, filename of the note | |
:param content: str, content of the note as markdown |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from dotenv import load_dotenv | |
from langchain.chat_models import ChatOpenAI | |
# Load env variables | |
load_dotenv() | |
llm = ChatOpenAI(temperature=0, tags=["tag-source-app-py"]) | |
print(llm.predict("Why do we finish a setup with hello, world!")) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* You can use any libraries imported in Flowise | |
* You can use properties specified in Output Schema as variables. Ex: Property = userid, Variable = $userid | |
* Must return a string value at the end of function | |
*/ | |
const fetch = require('node-fetch'); | |
const url = 'https://api.open-meteo.com/v1/forecast?latitude=' + $latitude + '&longitude=' + $longitude + '¤t_weather=true'; | |
const options = { | |
method: 'GET', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const fetch = require('node-fetch'); | |
const url = 'https://free-geo-ip.p.rapidapi.com/json/' + $ip; | |
const options = { | |
method: 'GET', | |
headers: { | |
'X-RapidAPI-Key': 'YOUR_RAPIDAPI_KEY', | |
'X-RapidAPI-Host': 'free-geo-ip.p.rapidapi.com' | |
} | |
}; |