Following the free open access language model in August 2024 Wisdom Spectrum supports 128K context/4K output length large model GLM-4-Flash full volume free open! With the concept of leading technology and benefiting the public, we have launched the first free multimodal model - GLM-4V-Flash on the bigmodel.cn open platform today, which inherits the advantages of the 4V series and makes breakthroughs in image processing accuracy, which will further lower the threshold for developers to tap the The model inherits the advantages of the 4V series and makes breakthroughs in image processing accuracy, which will further lower the threshold for developers to tap into the application of large models and open a new chapter.
We look forward to more developers joining the Bigmodel Open Platform (bigmodel.cn) to take advantage of GLM-4V-Flash's image processing, transform the modeling capabilities into practical applications, and enhance the efficiency and user experience in the fields of information extraction, content creation, and image recognition.
View free API: bigmodel.co.uk Documentation: bigmodel.cn/dev/api/normal-model/glm-4v
Tutorials
GLM-4V-Flash: Image url or base64 encoding. Image size upload limit is less than 5M per image, and the pixel is not more than 6000*6000. Support jpg, png, jpeg format. Note: GLM-4V-Flash does not support base64 encoding, only glm-4v-plus supports video input, concurrency limit: 2.
Upload Image URL
from zhipuai import ZhipuAI client = ZhipuAI(api_key="") # Fill in your own APIKey response = client.chat.completions.create( model="glm-4v", # Fill in the Name of the model to be called messages=[ { "role": "user", "content": [ { "type": "text", "text": "What's in the picture" }, { "type": "image_url", "image_url": { "url" : "https://img1. baidu.com/it/u=1369931113,3388870256&fm=253&app=138&size=w931&n=0&f=JPEG&fmt=auto?sec=1703696400&t= f3028c7a1dca43a080aeb8239f09cc2f" } } ] } ] ) print(response.choices[0].message)
Upload image Base64
import base64 from zhipuai import ZhipuAI img_path = "/Users/YourCompluter/xxxx.jpeg" with open(img_path, 'rb') as img_file: img_base = base64. b64encode(img_file.read()).decode('utf-8') client = ZhipuAI(api_key="YOUR API KEY") # Fill in your own APIKey response = client.chat.completions. create( model="glm-4v-plus", # Fill in the name of the model that needs to be called messages=[ { "role": "user", "content": [ { "type": "image_url", "image_url": { "url": img_base } }, { "type": "text", "text": "Please describe this image" } ] } ] ) print(response.choices[0].message)
Experience Address:(Only still images are allowed to be uploaded, motion pictures and videos are not supported)
https://glm4v.aisharenet.com/ (bolt is so handy in quickly verifying API function interactions, the website generated after directly uploading API documentation)