version: 1.0.0
last_updated: 2024-03-19
sections:
- core_requirements
- python_version
- code_style
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 are a powerful agentic AI coding assistant powered by Cursor. You operate exclusively in Cursor, the world's best IDE. | |
| You are pair programming with a USER to solve their coding task. | |
| Each time the USER sends a message, some information may be automatically attached about their current state, such as what files they have open, where their cursor is, recently viewed files, edit history in their session so far, linter errors, and more. | |
| This information may or may not be relevant to the coding task, it is up for you to decide. | |
| Your main goal is to follow the USER's instructions at each message. | |
| <communication> | |
| 1. Format your responses in markdown. Use backticks to format file, directory, function, and class names. |
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
| import argparse | |
| import random | |
| import sys | |
| from transformers import AutoModelForCausalLM, AutoTokenizer, DynamicCache | |
| import torch | |
| parser = argparse.ArgumentParser() | |
| parser.add_argument("question", type=str) | |
| parser.add_argument( |
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
| import asyncio | |
| import base64 | |
| import json | |
| import os | |
| import pyaudio | |
| from websockets.asyncio.client import connect | |
| class SimpleGeminiVoice: | |
| def __init__(self): |
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
| [package] | |
| name = "playground" | |
| version = "0.1.0" | |
| edition = "2021" | |
| [dependencies] | |
| alloy = { git = "https://github.com/alloy-rs/alloy.git", features = ["contract", "provider-ws", "rpc-types-eth"] } | |
| anyhow = "1.0.82" | |
| tokio = { version = "1.37.0", features = ["full"] } | |
| tracing = "0.1.40" |
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
| import json | |
| MIN_ERC20_ABI = json.loads( | |
| """ | |
| [{"constant": true, "inputs": [], "name": "name", "outputs": [ { "name": "", "type": "string" } ], "payable": false, "stateMutability": "view", "type": "function" }, { "constant": false, "inputs": [ { "name": "_spender", "type": "address" }, { "name": "_value", "type": "uint256" } ], "name": "approve", "outputs": [ { "name": "", "type": "bool" } ], "payable": false, "stateMutability": "nonpayable", "type": "function" }, { "constant": true, "inputs": [], "name": "totalSupply", "outputs": [ { "name": "", "type": "uint256" } ], "payable": false, "stateMutability": "view", "type": "function" }, { "constant": false, "inputs": [ { "name": "_from", "type": "address" }, { "name": "_to", "type": "address" }, { "name": "_value", "type": "uint256" } ], "name": "transferFrom", "outputs": [ { "name": "", "type": "bool" } ], "payable": false, "stateMutability": "nonpayable", "type": "function" }, { "constant": true, "inputs": [], "name": "decimals", "outputs": [ { "name" |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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
| #!/bin/bash | |
| # | |
| # convert a mysql database to sqlite3 | |
| # | |
| #see https://stackoverflow.com/questions/5164033/ | |
| # export-a-mysql-database-to-sqlite-database | |
| mysql_host=localhost | |
| mysql_user=george | |
| #mysql_passwd=**************** |
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
| """ | |
| preprocess-twitter.py | |
| python preprocess-twitter.py "Some random text with #hashtags, @mentions and http://t.co/kdjfkdjf (links). :)" | |
| Script for preprocessing tweets by Romain Paulus | |
| with small modifications by Jeffrey Pennington | |
| with translation to Python by Motoki Wu | |
| Translation of Ruby script to create features for GloVe vectors for Twitter data. |
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
| function svmStruct = best_svm_classifer_rbf(cdata,labels) | |
| %Write a function called crossfun to calculate the predicted classification yfit from a test vector | |
| %xtest, when the SVM is trained on a sample xtrain that has classification ytrain. | |
| function yfit = crossfun(xtrain,ytrain,xtest, rbf_sigma, boxconstraint) | |
| % Train the model on xtrain, ytrain, | |
| % and get predictions of class of xtest and output it as yfit |
NewerOlder