shipfeedAI news, curated daily

23:52:25 CET
20 MAY23:52:25shipfeed
pull to refreshlast sync
Just in — 30 new
§ feed · storyline

FIM Completion (Beta)

DeepSeek releases FIM (Fill In the Middle) completion in beta, allowing developers to provide prefix and suffix context for code and content generation via the deepseek-v4-pro model.

May 7 · · primary fetch1 sourceupdated May 7 ·

In FIM (Fill In the Middle) completion, users can provide a prefix and suffix (optional), and the model completes the content in the middle. FIM is commonly used for content continuation, code completion, and other scenarios. Notes The model's maximum completion length is 4K. Users need to set base_url="https://api.deepseek.com/beta" to enable Beta features. Sample Code Below is a complete Python code example for FIM completion. In this example, we provide the beginning and end of a Fibonacci sequence function to let the model complete the middle content.

from openai import OpenAI client = OpenAI( api_key="", base_url="https://api.deepseek.com/beta", ) response = client.completions.create( model="deepseek-v4-pro", prompt="def fib(a):", suffix=" return fib(a-1) + fib(a-2)", max_tokens=128 ) print(response.choices[0].text) Configure Continue Code Completion Plugin Continue is a VSCode plugin that supports code completion. You can refer to this documentation to configure Continue to use code completion features.

read full article on api-docs.deepseek.com
§ sources1 publication · timeline below
  1. api-docs.deepseek.comFIM Completion (Beta)primary