Skip to content

Instantly share code, notes, and snippets.

View descention's full-sized avatar

Scott Mundorff descention

View GitHub Profile
@descention
descention / ollama-autogen.py
Created March 13, 2024 13:24
OllamaModelClient for Autogen
import autogen
import ollama
import random
from ollama import ChatResponse
from autogen import AssistantAgent, ModelClient, UserProxyAgent
from types import SimpleNamespace
from autogen.agentchat.contrib.retrieve_assistant_agent import RetrieveAssistantAgent
from autogen.agentchat.contrib.retrieve_user_proxy_agent import RetrieveUserProxyAgent
config_list_custom = [{
public class MiningJob
{
public Asteroid TargetAsteroid { get; set; }
public int Row { get; set; }
public int Column { get; set; }
internal MiningVessel _vessel;
public bool FinishedBore { get; internal set; }
internal Size BoreSize{get;set;}
public MiningJob(Asteroid asteroid, MiningVessel vessel)
@descention
descention / automation.yaml
Created February 10, 2017 21:35
Discord sensor
- alias: What is being played?
trigger:
- platform: state
entity_id: sensor.gaming
action:
- service: notify.scott
data_template:
message: "{{ states.sensor.gaming }}"
@descention
descention / yaml.nanorc
Created January 25, 2017 18:01
Nano syntax highlighting for YAML files
## Nano syntax highlighting for YAML files
##
## Author: Leo Arnold
## License: Public Domain
## URL: https://gist.github.com/leoarnold/96272e33753aff09163cf18ad641f028
syntax "yaml" "\.(yml|yaml)$"
## Keys
icolor green "^[[:space:]]*(- )?[.0-9A-Z_/-]+:( |$)"
@descention
descention / switch.yaml
Last active February 1, 2017 05:14
RM Mini 3 configuration for hass
- platform: broadlink
host: 192.168.100.109
mac: 'removed'
switches:
tv_power:
friendly_name: "TV Power"
command_on: 'JgBIAAABJZMTEhMSEzYSExITERQRExMSEjcTNhMSEzYTNhI3EzYTNhITEhMRFBE4EhITEhITExITNhM2EzYTEhI3EzYROBI3EgANBQ=='
command_off: 'JgBIAAABJZMTEhMSEzYSExITERQRExMSEjcTNhMSEzYTNhI3EzYTNhITEhMRFBE4EhITEhITExITNhM2EzYTEhI3EzYROBI3EgANBQ=='
- platform: template