You can create [objects in ReasonML][1]. For example:
let document = {
pub title = "My Treatise";
pub contents = "<a lot of words>"
};
users = User.arel_table | |
query = users.project(users[Arel.star]) |
Assuming that [Conda][1] is used, start by creating an environment for NeoVim:
$ conda create -n neovim36 python=3.6
Fish shell users:
$ source (conda info --root)/etc/fish/conf.d/conda.fish
In Rails 5, the preferred base class for testing controllers is ActionDispatch::IntegrationTest
.
If you have an API that receives parameters as JSON request bodies, here are some helper methods to facilitate testing:
class ActionDispatch::IntegrationTest
def put_json(path, obj)
put path, params: obj.to_json, headers: { 'CONTENT_TYPE' => 'application/json' }
end
In Genshin Impact, you can craft materials of a given rank from three materials of the rank just below, eg. you can craft one gold book from three blue books.
Albedo has a talent where crafting a weapon ascension material has a 10% chance of giving double the output. Mona has a talent where crafting a weapon ascension material has a 25% chance of refunding a portion of the input materials.
This is always an annoying process, especially when you are setting up a new computer. I assume you are using macOS + homebrew. I also assume that you want to run an older version of MySQL (although the instructions should be adaptable).
$ brew install mysql@5.7 # change the version if needed
[merge] | |
tool = vimdiff | |
[mergetool] | |
keepBackup = false | |
[mergetool "vimdiff"] | |
cmd = nvim -d $LOCAL $REMOTE $MERGED -c '$wincmd w' -c 'wincmd J' |
You are writing a spec with type: :request
, i.e. an integration spec instead
of a controller spec. Integration specs are wrappers around Rails'
ActionDispatch::IntegrationTest
class. I usually write controller tests using
this instead of type: :controller
, mainly because it exercises more of the
request and response handling stack. So instead of writing something like
get :index
to start the request, you would write get books_path
or similar.
One of the issues with using type: :request
is that you lose the ability to
These are notes on how I managed to get StarCoderBase-1B-SFT model compiled into a quantized version such that it can run locally on my MBP M1 Pro and be queryable through an OpenAI API-compatible server. [StarCoderBase][1] is a model trained/tuned for programming tasks. The [1B parameters SFT model][2] I am using in this article is a version of the model that has had supervised fine tuning applied to it. I am just going to call this "StarCoder" in the rest of this article for the sake of simplicity. Number of parameters that a model has is going to impact resource usage, so a smaller version of the model makes it more