SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2403.06634 · 2024

Stealing Part of a Production Language Model

arXiv · PDF · Open in the Atlas

Code that ran

We lifted 4 functions out of this paper's own repositories and ran 4 of them in a sandbox. "Ran" means the function executed on a synthesized input and returned a value. It is not a reproduction of the paper's results.

RepositoryRoleRan
dpaleka/stealing-part-lm-supplementary canonical 4 of 4
FunctionStatusWhere it lives
carlini_error Ran dpaleka/stealing-part-lm-supplementary/optimize_logit_queries/run_attack.py
code served (permissive licence) · get_code("94df5abf385c6b88")
is_proper Ran dpaleka/stealing-part-lm-supplementary/optimize_logit_queries/run_attack.py
code served (permissive licence) · get_code("1409088ddeb0b23c")
make_chat_logprob_dict_from_completion_data Ran dpaleka/stealing-part-lm-supplementary/query_logprobs_emulator/query_logprobs.py
code served (permissive licence) · get_code("5225f4c99476dfaf")
make_proper Ran dpaleka/stealing-part-lm-supplementary/optimize_logit_queries/run_attack.py
code served (permissive licence) · get_code("3665c1c5ad3a4358")

Repositories linked to this paper

Some links come from the archived Papers with Code dataset (CC BY-SA 4.0): attribution and licence.

Abstract

We introduce the first model-stealing attack that extracts precise, nontrivial information from black-box production language models like OpenAI's ChatGPT or Google's PaLM-2. Specifically, our attack recovers the embedding projection layer (up to symmetries) of a transformer model, given typical API access. For under \$20 USD, our attack extracts the entire projection matrix of OpenAI's Ada and Babbage language models. We thereby confirm, for the first time, that these black-box models have a hidden dimension of 1024 and 2048, respectively. We also recover the exact hidden dimension size of the gpt-3.5-turbo model, and estimate it would cost under $2,000 in queries to recover the entire projection matrix. We conclude with potential defenses and mitigations, and discuss the implications of possible future work that could extend our attack.

For agents

The same record, over MCP at https://syntology.ai/mcp:

get_harvested_code_for_paper("2403.06634")
get_code_for_paper("2403.06634")
have("2403.06634")

Connect an agent — have() is free.