Downloads · 30 days
6
16% of all-time downloads
ssfc/pcf-qwen3.5-9b-detail-to-detail-lora
pcf-qwen3.5-9b-detail-to-detail-lora is a text generation model from ssfc. Use it when you need the model to write or continue text. It is set up for peft.
This repository contains an experimental lightweight LoRA adapter for Qwen/Qwen3.5-9B trained for the Past-Creates-Future (PCF) algorithm-idea generation workflow.
Downloads · 30 days
6
16% of all-time downloads
All-time downloads
38
Public
Repo size
136 MB
Likes
0
Public
Click a slice to open those files.
.safetensors116 MB · 85%
From the Hugging Face model README
This repository contains an experimental lightweight LoRA adapter for Qwen/Qwen3.5-9B trained for the Past-Creates-Future (PCF) algorithm-idea generation workflow.
The model is trained to transform structured details of an existing algorithm plus a mechanism-level method delta into structured details of a possible improved algorithm:
existing method detail + method delta -> new method detail
This adapter is intended as a smaller alternative to the stronger Qwen/Qwen3-14B PCF detail-to-detail adapter. In local PCF evaluation it produced stable JSON outputs, but did not outperform the Qwen3-14B detail-to-detail adapter.
Qwen/Qwen3.5-9Bq_proj, k_proj, v_proj, o_proj, gate_proj, up_proj, down_projThis model is intended for algorithm-research ideation:
Generated algorithm claims should be treated as hypotheses. They require human inspection, implementation, and benchmark validation.
The input prompt contains structured existing method details with fields such as:
problem_definition
method_name
method_type
core_idea
key_components
input_output
optimization_objective
algorithm_flow
assumptions
limitations
novelty_claim
prior_work_relation
transferable_delta_hints
The method delta contains fields such as:
new_title
problem_shift
method_delta
component_changed
mechanism_added
mechanism_removed
abstraction_shift
why_improves
reuse_pattern
delta_keywords
The expected output is valid JSON with the same method-detail fields.
import torch
from peft import PeftModel
from transformers import AutoModelForCausalLM, AutoTokenizer, BitsAndBytesConfig
base_model = "Qwen/Qwen3.5-9B"
adapter = "ssfc/pcf-qwen3.5-9b-detail-to-detail-lora"
tokenizer = AutoTokenizer.from_pretrained(base_model, trust_remote_code=True)
quantization_config = BitsAndBytesConfig(
load_in_4bit=True,
bnb_4bit_compute_dtype=torch.bfloat16,
bnb_4bit_use_double_quant=True,
bnb_4bit_quant_type="nf4",
)
model = AutoModelForCausalLM.from_pretrained(
base_model,
device_map="auto",
quantization_config=quantization_config,
trust_remote_code=True,
)
model = PeftModel.from_pretrained(model, adapter)
model.eval()
For the prompt construction used in this project, see finetune/inference_detail.py in the Past-Creates-Future repository.
Training data file:
deepseek_method_delta_details_v4_flash_30k5562_detail_to_detail_conf0p6.jsonl
The dataset was built from algorithm papers. The pipeline extracts structured method details for old and new methods, summarizes method deltas, filters examples by confidence, and formats examples as:
existing detail + delta detail -> new detail
This version uses a 30k-character extraction context and a confidence threshold of 0.6.
Local held-out PCF evaluation with 24 examples:
valid_json_rate: 1.0
detail_fields_rate: 1.0
mean_keyword_coverage: 0.232
mean_compact_reference_word_jaccard: 0.246
mean_output_chars: 4009
Comparison against the Qwen3-14B detail-to-detail adapter on the same 24-example split:
Qwen3.5-9B mean_keyword_coverage: 0.232
Qwen3-14B mean_keyword_coverage: 0.260
The Qwen3.5-9B adapter is therefore useful as a lightweight experimental alternative, while the Qwen3-14B detail-to-detail adapter remains the stronger default in local PCF experiments.
Use this model to generate candidate method details, then: