Skip to content

Instantly share code, notes, and snippets.

Model Input (USD) Output (USD)
Mistral 7B $0.25 / 1M tokens $0.25 / 1M tokens
Mixtral 8x7B $0.7 / 1M tokens $0.7 / 1M tokens
Mistral Small $2 / 1M tokens $6 / 1M tokens
Mistral Medium $2.7 / 1M tokens $8.1 / 1M tokens
Mistral Large $8 / 1M tokens $24 / 1M tokens
gpt-4-0125-preview $10.00 / 1M tokens $30.00 / 1M tokens
gpt-3.5-turbo-0125 $0.50 / 1M tokens $1.50 / 1M tokens
gpt-3.5-turbo-instruct $1.50 / 1M tokens $2.00 / 1M tokens
Model Input (USD) Output (USD)
Mistral 7B $0.25 / 1M tokens $0.25 / 1M tokens
Mixtral 8x7B $0.7 / 1M tokens $0.7 / 1M tokens
Mistral Small $2 / 1M tokens $6 / 1M tokens
Mistral Medium $2.7 / 1M tokens $8.1 / 1M tokens
Mistral Large $8 / 1M tokens $24 / 1M tokens
gpt-4-0125-preview $10.00 / 1M tokens $30.00 / 1M tokens
gpt-3.5-turbo-0125 $0.50 / 1M tokens $1.50 / 1M tokens
gpt-3.5-turbo-instruct $1.50 / 1M tokens $2.00 / 1M tokens
@sj82516
sj82516 / main.rb
Last active March 29, 2023 00:51
contain_7s
# case
# 0, 1, 2, 3, 4, 6, 7, 8, 9
# 10 ............., 17, 18, 19
# 20, ............, 27, 28, 29
# 10 -> 1
# 20 -> 2
# 30 -> 3
# .....
# 70 -> 8
# 80 -> 10 (70~79) + 7 = 17
@sj82516
sj82516 / traveler.cpp
Created July 28, 2021 23:44
traveler
class Solution {
public:
/**
* @param n: an integer,denote the number of cities
* @param roads: a list of three-tuples,denote the road between cities
* @return: return the minimum cost to travel all cities
*/
int minCost(int n, vector<vector<int>> &roads) {
// unordered_map<int, vector<pair<int, int>>> graph;
// constructGraph(roads, graph);
export class Solution {
/**
* business
*
* @param A: The prices [i]
* @param k:
* @return: The ans array
*/
business(A, k) {
@sj82516
sj82516 / arraySum.go
Last active March 10, 2021 00:59
arraySum
package main
import (
"fmt"
"math"
"math/rand"
"sync"
"sync/atomic"
"time"
)
@sj82516
sj82516 / http.go
Last active March 11, 2021 23:40
Nodejs vs Golang: http request
package main
import (
"encoding/json"
"fmt"
"io"
"net/http"
)
type UsersResp struct {
@sj82516
sj82516 / a.js
Created July 20, 2020 08:23
Nodejs Dependency Circulation
module.exports = {
data: "This is a",
};
const b = require('./b.js');
console.log(b.data);
@sj82516
sj82516 / #11-Container With Most Water.cpp
Last active May 9, 2020 10:04
LeetCode Week 1 - Array
// 從兩頭開始算容積,接著把矮的一邊往內縮持續比對
// 時間複雜度: O(n) / 空間複雜度 O(1)
class Solution {
public:
int maxArea(vector<int>& height) {
int result = 0;
int length = height.size();
int left = 0;
int right = length - 1;
int containerWidth = 0;
const expect = require('chai').expect;
const sinon = require('sinon');
const UserManager = require('../../user/user.manager');
describe('userManger', () => {
let userManager = null;
let sandbox = sinon.createSandbox();
const findUserStub = sandbox.stub();