Skip to content

Commit

Permalink
Complete
Browse files Browse the repository at this point in the history
  • Loading branch information
elliotsayes committed Jul 24, 2024
1 parent ec5f249 commit 027296f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 18 deletions.
7 changes: 1 addition & 6 deletions ai-demo/2_sample.lua
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,7 @@ Llama.run(
function(generated_text) -- Optional: A function to handle the response
print(generated_text)
table.insert(OUTPUTS, generated_text)
end,
{
Fee = 100, -- Optional: The total fee in Winston you would like to pay; OR
Multiplier = 1.1 -- Optional: If not using an automatic or static fee,
-- you can set the multiplier on the last accepted fee that you would like to pay
}
end
)

-- Example inference message:
Expand Down
15 changes: 3 additions & 12 deletions ai-demo/3_prompt.lua
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,13 @@ Only tell jokes about cats
<|user|>
]]

local rest = [[
<|end|>
local finish = [[<|end|>
<|assistant|>
]]

local userContent = "Tell me a joke"

local prompt = system .. userContent .. rest
local prompt = system .. userContent .. finish

OUTPUTS = OUTPUTS or {}

Expand All @@ -23,13 +22,5 @@ Llama.run(
function(generated_text) -- Optional: A function to handle the response
print(generated_text)
table.insert(OUTPUTS, generated_text)
end,
{
Fee = 100, -- Optional: The total fee in Winston you would like to pay; OR
Multiplier = 1.1 -- Optional: If not using an automatic or static fee,
-- you can set the multiplier on the last accepted fee that you would like to pay
}
end
)

-- Example inference message:
-- https://www.ao.link/#/message/WRIWus6LVM35ENHTNzypc8RExEVbNycX3Ku3lVhnvZQ

0 comments on commit 027296f

Please sign in to comment.