Text specification generation method and device, storage medium and electronic equipment

By obtaining the text attributes in the design drawing file and using a large language model to generate text style information, and automatically generate text specifications, the cumbersome process of creating text specifications in the existing technology is solved, and the generation efficiency and readability of the design drawing are improved.

CN118916019APending Publication Date: 2024-11-08BEIJING CHUANGZUOMEIHAO TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410701052.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-05-31
Publication Date
2024-11-08

AI Technical Summary

Technical Problem

The process of creating text specifications in the prior art is cumbersome and inefficient, and designers need to manually extract style information and perform semantic naming.

Method used

By obtaining the text attributes in the design drawing file, filtering and processing, using the large language model to generate text style information, automatically generating text specifications, and reducing designer verification and naming operations.

Benefits of technology

It improves the generation efficiency of text specifications, simplifies the designer's workflow, and improves the readability and drawing efficiency of design drawings.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118916019A_ABST
    Figure CN118916019A_ABST
Patent Text Reader

Abstract

The invention provides a text specification generation method and device, a storage medium and electronic equipment. The method comprises the steps of obtaining text attributes of each text layer in a design drawing file; the character attributes comprise a first type of attribute and a second type of attribute; the first type of attributes comprise fonts, and the second type of attributes comprise at least one of font size, font weight, row height and font spacing; screening the character attributes to obtain a first type of target attributes and a plurality of second type of target attributes; according to a preset prompt prompt and each second type of target attribute, obtaining character style information through a preset large language model; and generating a text specification according to the first type of target attribute and the text style information. According to the method provided by the embodiment of the invention, the text specification can be automatically generated without tedious verification and naming operations of a designer, so that the generation efficiency of the text specification is effectively improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of computer technology, and in particular to a text standard generation method, device, storage medium and electronic equipment. Background Art

[0002] In the process of designers drawing design drawings, they usually draw the design drawings based on their visual feelings and experience. After determining the visual effect, they will create the text attributes in the design drawings into text specifications one by one.

[0003] In the prior art, when creating text specifications, it is usually necessary to use extraction technology to extract the style of the design drawing, and then the designer checks the extracted style information one by one and performs semantic naming. The entire process of creating text specifications is cumbersome, which makes the efficiency of creating text specifications low. Summary of the invention

[0004] The technical problem to be solved by the present invention is to provide a method, device, storage medium and electronic device for generating text specifications, which can improve the efficiency of generating text specifications. The specific scheme is as follows:

[0005] A method for generating text specifications, comprising:

[0006] Acquire text attributes of each text layer in the design drawing file; the text attributes include first-type attributes and second-type attributes; the first-type attributes include fonts, and the second-type attributes include at least one of font size, font weight, line height, and character spacing;

[0007] Screening and processing each of the text attributes to obtain a first type target attribute and a plurality of second type target attributes;

[0008] According to the preset prompt and each of the second-type target attributes, obtaining text style information through a preset large language model;

[0009] Generate a text specification according to the first type target attribute and the text style information.

[0010] In the above method, optionally, the filtering of each of the text attributes to obtain a first type target attribute and a plurality of second type target attributes includes:

[0011] Selecting a plurality of target text attributes from each of the text attributes, wherein the font size of each of the target text attributes is greater than or equal to a preset font size threshold;

[0012] Determine the first type attribute with the largest number of uses among the target text attributes as the first type target attribute;

[0013] The second type attributes of each of the target text attributes are divided to obtain a plurality of second type attribute sets; each of the second type attributes in each of the second type attribute sets has the same font size and the same font weight;

[0014] The second type attributes in each second type attribute set are merged to obtain the second type target attributes corresponding to each second type attribute set; the second type target attributes corresponding to each second type attribute set include the font size, font weight, target line height and target character spacing of the second type attribute set; the target line height is the line height used most in the second type attribute set; the target character spacing is the character spacing used most in the second type attribute set.

[0015] In the above method, optionally, obtaining text style information through a preset large language model according to a preset prompt and each of the second-type target attributes includes:

[0016] Obtaining a preset first prompt and a second prompt; the first prompt is used to indicate generating style information based on each of the second-type target attributes; the second prompt is used to indicate determining whether the style information meets the design specification, and if the style information does not meet the design specification, modifying the style information;

[0017] Each of the second-type target attributes, the first prompt, and the second prompt is input into a preset large language model to obtain text style information that meets the design specifications.

[0018] In the above method, optionally, the step of inputting each of the second-type target attributes, the first prompt, and the second prompt into a preset large language model to obtain text style information that meets the design specification includes:

[0019] sorting each of the second-type target attributes according to the font size and / or font weight in each of the second-type target attributes;

[0020] The sorted second-type target attributes, the first prompt, and the second prompt are input into a preset large language model to obtain text style information that meets the design specifications.

[0021] The above method may, optionally, further include: after generating the text specification according to the first type target attribute and the text style information, the method may further include:

[0022] Creating a text style in the design drawing file according to the text specification;

[0023] An illustration of the text specification is generated within the canvas of the design drawing file.

[0024] A text specification generating device, comprising:

[0025] An acquisition unit, used for acquiring text attributes of each text layer in the design drawing file; the text attributes include first-type attributes and second-type attributes; the first-type attributes include fonts, and the second-type attributes include at least one of font size, font weight, line height, and character spacing;

[0026] A first execution unit is used to filter and process each of the text attributes to obtain a first type target attribute and a plurality of second type target attributes;

[0027] A first execution unit, configured to obtain text style information through a preset large language model according to a preset prompt and each of the second-type target attributes;

[0028] A generating unit is used to generate a text specification according to the first type target attribute and the text style information.

[0029] In the above device, optionally, the first execution unit includes:

[0030] A selection subunit, used to select a plurality of target text attributes from each of the text attributes, wherein the font size of each of the target text attributes is greater than or equal to a preset font size threshold;

[0031] A determination subunit, configured to determine the first type of attribute with the largest number of uses among the target text attributes as the first type of target attribute;

[0032] an attribute division subunit, configured to divide the second type attributes of each of the target text attributes to obtain a plurality of second type attribute sets; each of the second type attributes in each of the second type attribute sets has the same font size and the same font weight;

[0033] The first execution sub-unit is used to merge the second type attributes in each second type attribute set to obtain the second type target attributes corresponding to each second type attribute set; the second type target attributes corresponding to each second type attribute set include the font size, font weight, target line height and target character spacing of the second type attribute set; the target line height is the line height with the largest number of uses in the second type attribute set; the target character spacing is the character spacing with the largest number of uses in the second type attribute set.

[0034] In the above device, optionally, the second execution unit includes:

[0035] an acquisition subunit, used for acquiring a preset first prompt and a second prompt; the first prompt is used for indicating generation of style information based on each second-type target attribute; the second prompt is used for indicating determination of whether the style information meets the design specification, and if the style information does not meet the design specification, the style information is modified;

[0036] The second execution subunit is used to input each of the second-type target attributes, the first prompt and the second prompt into a preset large language model to obtain text style information that meets the design specifications.

[0037] A storage medium includes storage instructions, wherein when the instructions are executed, the device where the storage medium is located is controlled to execute the text specification generation method as described above.

[0038] An electronic device includes a memory and one or more instructions, wherein the one or more instructions are stored in the memory and are configured to be executed by one or more processors to perform the above-mentioned text specification generation method.

[0039] Based on the above-mentioned implementation of the present invention, a method, device, storage medium and electronic device for generating text specifications are provided, the method comprising: obtaining text attributes of each text layer in a design drawing file; the text attributes include first-type attributes and second-type attributes; the first-type attributes include fonts, and the second-type attributes include at least one of font size, font weight, line height and character spacing; screening and processing each of the text attributes to obtain a first-type target attribute and multiple second-type target attributes; obtaining text style information through a preset large language model according to a preset prompt and each of the second-type target attributes; generating text specifications according to the first-type target attributes and the text style information. The method provided by the embodiment of the present invention can obtain text style information based on the second-type target attributes through a large language model, and then automatically generate text specifications according to the first-type target attributes and the text style information, without the need for designers to perform tedious verification and naming operations, effectively improving the efficiency of generating text specifications. BRIEF DESCRIPTION OF THE DRAWINGS

[0040] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without paying creative work.

[0041] Figure 1 A method flow chart of a text specification generation method provided by the present invention;

[0042] Figure 2 A flowchart of a process of obtaining a first type of target attribute and a second type of target attribute provided by the present invention;

[0043] Figure 3 An example diagram of a text specification provided by the present invention;

[0044] Figure 4 A structural schematic diagram of a text standard generating device provided by the present invention;

[0045] Figure 5 The present invention provides a schematic structural diagram of an electronic device. DETAILED DESCRIPTION

[0046] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0047] In this application, the terms "comprises", "comprising" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device comprising a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "comprising a ..." does not exclude the presence of other identical elements in the process, method, article or device comprising the element.

[0048] The embodiment of the present invention provides a method for generating text specifications, which can be applied to electronic devices. The method flow chart of the method is as follows: Figure 1 As shown, specifically including:

[0049] S101: Obtain text attributes of each text layer in the design drawing file; the text attributes include first-type attributes and second-type attributes; the first-type attributes include fonts, and the second-type attributes include at least one of font size, font weight, line height, and character spacing.

[0050] In this embodiment, the design drawing file may include one or more text layers.

[0051] S102: Screening and processing each of the text attributes to obtain a first type target attribute and a plurality of second type target attributes.

[0052] In this embodiment, the first type of target attribute may be a target font, and the second type of target attribute may include at least one of a target font size, a target font weight, a target line height, and a target character spacing.

[0053] Optionally, each text attribute may be screened according to a preset rule to obtain a first type target attribute and a plurality of second type target attributes.

[0054] In an embodiment of the present invention, the process of screening each of the text attributes to obtain a first type target attribute and a plurality of second type target attributes is as follows: Figure 2 As shown, including:

[0055] S201: Select a plurality of target text attributes from the various text attributes, wherein the font size of each of the target text attributes is greater than or equal to a preset font size threshold.

[0056] In this embodiment, for each text attribute, the font size in the text attribute is compared with a preset font size threshold. If the font size in the text attribute is greater than or equal to the font size threshold, the text attribute is determined as the target text attribute; if the font size in the text attribute is less than the font size threshold, the text attribute may not be processed or may be discarded.

[0057] Optionally, the font size threshold can be set based on actual needs. For example, it can be set to 10px. In this case, if the text attributes in the design file include the following font sizes: 16px, 14px, 10px, 8px, 7px, then the text attributes with font sizes of 8px and 7px are discarded, and the text attributes with font sizes of 16px, 14px, and 10px are used as the target text attributes.

[0058] S202: Determine the first type attribute with the largest number of uses among the target text attributes as the first type target attribute.

[0059] In this embodiment, the most used first type attribute among the target text attributes may be determined, that is, the most used font among the target text attributes may be determined; and the most used font may be determined as the first type target attribute.

[0060] S203: Divide the second type attributes of each of the target text attributes to obtain a plurality of second type attribute sets; each of the second type attributes in each of the second type attribute sets has the same font size and the same font weight.

[0061] In this embodiment, each target text attribute can be divided according to the font size and font weight in each target text attribute to obtain multiple second type attribute sets; specifically, target text attributes with the same font size and font weight can be grouped into one second type attribute set; the second type attributes in different second type attribute sets have different font sizes and / or font weights.

[0062] S204: Merge the second type attributes in each second type attribute set to obtain the second type target attributes corresponding to each second type attribute set; the second type target attributes corresponding to each second type attribute set include the font size, font weight, target line height and target character spacing of the second type attribute set; the target line height is the line height with the largest number of uses in the second type attribute set; the target character spacing is the character spacing with the largest number of uses in the second type attribute set.

[0063] In this embodiment, for each second type attribute set, the number of times the line height and character spacing of each second type attribute in the second type attribute set are used is counted, and the line height with the most times of use is determined as the target line height of the second type attribute set, and the character spacing with the most times of use is determined as the target character spacing of the second type attribute set. Then, the font size, font weight, target line height and target character spacing of the second type attributes in the second type attribute set constitute the second type target attributes corresponding to the second type attribute set.

[0064] For example, the second type attribute set includes:

[0065] The second type of attributes 1: "font-size: 16px, font-weight: 700, line-height: 28px, letter-spacing: 0em";

[0066] Second type of attributes 2: "font-size:16px, font-weight:700, line-height:24px, letter-spacing:0em";

[0067] Second type of attributes 3: "font-size: 16px, font-weight: 700, line-height: 24px, letter-spacing: 0.2em".

[0068] The second type of target attributes obtained after merging are: "font-size: 16px, font-weight: 700, line-height: 24px, letter-spacing: 0em".

[0069] S103: According to the preset prompt and each of the second-type target attributes, obtain text style information through a preset large language model.

[0070] In this embodiment, the prompt may be used to instruct to generate text style information in a specified format based on each second-type target attribute.

[0071] Optionally, the format of the text style information may be in json format, and the text style information may include a font size, font weight, line height, and character spacing that meet design specifications.

[0072] S104: Generate a text specification according to the first type target attribute and the text style information.

[0073] By applying the method provided in the embodiment of the present invention, the efficiency of generating text specifications is effectively improved by generating text specifications according to the first type of target attributes and text style information, thereby improving the readability of the design drawing and improving the efficiency of drawing the design drawing.

[0074] In an embodiment provided by the present invention, based on the above implementation process, optionally, after generating the text specification according to the first type target attribute and the text style information, the method further includes:

[0075] Creating a text style in the design drawing file according to the text specification;

[0076] An illustration of the text specification is generated within the canvas of the design drawing file.

[0077] In this embodiment, if Figure 3 As shown, after generating the text specification, you can create a corresponding text style in the design drawing file and generate an illustration of the text specification in the canvas.

[0078] By applying the method provided in the embodiment of the present invention, by creating text styles and illustrations of text specifications in a design drawing file, it is possible to effectively provide inspiration and reference for designers to create text specifications, thereby assisting designers in creating design drawings with excellent text effects.

[0079] In an embodiment of the present invention, based on the above implementation process, optionally, obtaining text style information through a preset large language model according to a preset prompt and each second-type target attribute includes:

[0080] Obtaining a preset first prompt and a second prompt; the first prompt is used to indicate generating style information based on each of the second-type target attributes; the second prompt is used to indicate determining whether the style information meets the design specification, and if the style information does not meet the design specification, modifying the style information;

[0081] Each of the second-type target attributes, the first prompt, and the second prompt is input into a preset large language model to obtain text style information that meets the design specifications.

[0082] In this embodiment, the first prompt, each second type target attribute and the second prompt may be concatenated, and then the concatenated prompt text may be input into the large language model.

[0083] Optionally, the first prompt may include:

[0084] “Please play the role of an expert in the field of UI design, and you are proficient in how to establish a UI design specification.

[0085] The first step is to learn the following seven text styles. The descriptions of the styles are in brackets:

[0086] h1 (extra large title font size);

[0087] h2 (large title font size);

[0088] h3 (title font size);

[0089] h4 (subheading font size);

[0090] body-bold (bold text, same font size as body, but bolder);

[0091] body(text size);

[0092] caption (the smallest font size, usually used for annotation text);

[0093] In the second step, please select attribute values ​​from the following attributes and fill them into the style table above. Each style has a unique value.

[0094] If there is no matching value in the following attribute values, please help me choose a reasonable value to fill in.

[0095] Optionally, each second-type target attribute can be expressed as: {{.FontStyle}}.

[0096] Optionally, the second prompt may include:

[0097] "In the third step, do not give an answer after filling in the attributes. Check the results first to determine whether the selected attribute values ​​meet the UI design specifications. If not, please make corrections until they meet the design specifications and then give the final answer. Please return the final answer in json format."

[0098] In an embodiment provided by the present invention, based on the above implementation process, optionally, inputting each of the second-type target attributes, the first prompt, and the second prompt into a preset large language model to obtain text style information that meets the design specification includes:

[0099] sorting each of the second-type target attributes according to the font size and / or font weight in each of the second-type target attributes;

[0100] The sorted second-type target attributes, the first prompt, and the second prompt are input into a preset large language model to obtain text style information that meets the design specifications.

[0101] In this embodiment, the merged text attributes may be arranged in descending order by font size, or in descending order by font weight if the font sizes are the same.

[0102] For example, after sorting each second type target attribute, the second type target attributes finally obtained are as follows:

[0103] Table 1

[0104]

[0105] In this embodiment, the sorted second-type target attributes are concatenated after the first prompt and before the second prompt to obtain a target prompt, and then the target prompt is input into the large language model, so that the large language model generates style information based on the first prompt and the sorted second-type target attribute information, and then the style information is determined according to the instruction of the second prompt. If the style information is determined to meet the design specifications, the style information is output as text style information; if the style information is determined not to meet the design specifications, the style information is modified to obtain text style information that meets the design specifications, and then output.

[0106] and Figure 1 Corresponding to the method described above, the embodiment of the present invention further provides a text specification generating device for Figure 1 The specific implementation of the method is shown in the following diagram: Figure 4 As shown, including:

[0107] The acquisition unit 401 is used to acquire the text attributes of each text layer in the design file; the text attributes include first-type attributes and second-type attributes; the first-type attributes include fonts, and the second-type attributes include at least one of font size, font weight, line height, and character spacing;

[0108] A first execution unit 402 is used to filter and process each of the text attributes to obtain a first type target attribute and a plurality of second type target attributes;

[0109] The second execution unit 403 is used to obtain text style information through a preset large language model according to a preset prompt and each of the second-type target attributes;

[0110] The generating unit 404 is configured to generate a text specification according to the first type target attribute and the text style information.

[0111] In an embodiment provided by the present invention, based on the above solution, optionally, the first execution unit 402 includes:

[0112] A selection subunit, configured to select a plurality of target text attributes from each of the text attributes, wherein the font size of each of the target text attributes is greater than or equal to a preset font size threshold;

[0113] A determination subunit, configured to determine the first type of attribute with the largest number of uses among the target text attributes as the first type of target attribute;

[0114] an attribute division subunit, configured to divide the second type attributes of each of the target text attributes to obtain a plurality of second type attribute sets; each of the second type attributes in each of the second type attribute sets has the same font size and the same font weight;

[0115] The first execution sub-unit is used to merge the second type attributes in each second type attribute set to obtain the second type target attributes corresponding to each second type attribute set; the second type target attributes corresponding to each second type attribute set include the font size, font weight, target line height and target character spacing of the second type attribute set; the target line height is the line height with the largest number of uses in the second type attribute set; the target character spacing is the character spacing with the largest number of uses in the second type attribute set.

[0116] In an embodiment provided by the present invention, based on the above solution, optionally, the second execution unit 403 includes:

[0117] an acquisition subunit, used for acquiring a preset first prompt and a second prompt; the first prompt is used for indicating generation of style information based on each second-type target attribute; the second prompt is used for indicating determination of whether the style information meets the design specification, and if the style information does not meet the design specification, the style information is modified;

[0118] The second execution subunit is used to input each of the second-type target attributes, the first prompt and the second prompt into a preset large language model to obtain text style information that meets the design specifications.

[0119] In an embodiment provided by the present invention, based on the above solution, optionally, the second execution subunit includes:

[0120] a sorting module, configured to sort each of the second-type target attributes according to the font size and / or font weight in each of the second-type target attributes;

[0121] An execution module is used to input the sorted second-type target attributes, the first prompt and the second prompt into a preset large language model to obtain text style information that meets the design specifications.

[0122] In an embodiment provided by the present invention, based on the above solution, optionally, the text standard generating device further includes:

[0123] A creation unit, used for creating a text style in the design drawing file according to the text specification;

[0124] A processing unit is used to generate an illustration of the text specification in the canvas of the design drawing file.

[0125] The specific principles and execution processes of each unit and module in the text standard generation device disclosed in the above embodiment of the present invention are the same as those of the text standard generation method disclosed in the above embodiment of the present invention. Please refer to the corresponding parts of the text standard generation method provided in the above embodiment of the present invention, and will not be repeated here.

[0126] An embodiment of the present invention further provides a storage medium, which includes stored instructions, wherein when the instructions are executed, the device where the storage medium is located is controlled to execute the above-mentioned text specification generation method.

[0127] The embodiment of the present invention further provides an electronic device, the structural diagram of which is shown in FIG. Figure 5As shown, it specifically includes a memory 501 and one or more instructions 502, wherein the one or more instructions 502 are stored in the memory 501 and are configured to be executed by one or more processors 503 to perform the following operations:

[0128] Acquire text attributes of each text layer in the design drawing file; the text attributes include first-type attributes and second-type attributes; the first-type attributes include fonts, and the second-type attributes include at least one of font size, font weight, line height, and character spacing;

[0129] Screening and processing each of the text attributes to obtain a first type target attribute and a plurality of second type target attributes;

[0130] According to the preset prompt and each of the second-type target attributes, obtaining text style information through a preset large language model;

[0131] Generate a text specification according to the first type target attribute and the text style information.

[0132] It should be noted that each embodiment in this specification is described in a progressive manner, and each embodiment focuses on the differences from other embodiments, and the same or similar parts between the embodiments can be referred to each other. For the device embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.

[0133] Finally, it should be noted that, in this article, relational terms such as first and second, etc. are merely used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations.

[0134] For the convenience of description, the above device is described as being divided into various units according to their functions. Of course, when implementing the present invention, the functions of each unit can be implemented in the same or multiple software and / or hardware.

[0135] It can be known from the description of the above implementation methods that those skilled in the art can clearly understand that the present invention can be implemented by means of software plus a necessary general hardware platform. Based on such an understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art can be embodied in the form of a software product, which can be stored in a storage medium such as ROM / RAM, a magnetic disk, an optical disk, etc., and includes a number of instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in the various embodiments of the present invention or certain parts of the embodiments.

[0136] The above is a detailed introduction to a text standard generation method provided by the present invention. Specific examples are used in this article to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only used to help understand the method of the present invention and its core idea; at the same time, for general technical personnel in this field, according to the idea of ​​the present invention, there will be changes in the specific implementation method and application scope. In summary, the content of this specification should not be understood as a limitation on the present invention.

Claims

1. A method for generating text specifications, It is characterized in that include: Get the text properties of each text layer in the design file; The text attributes include first-type attributes and second-type attributes; the first-type attributes include fonts, and the second-type attributes include at least one of font size, font weight, line height, and character spacing; Screening and processing each of the text attributes to obtain a first type target attribute and a plurality of second type target attributes; According to the preset prompt and each of the second-type target attributes, obtaining text style information through a preset large language model; Generate a text specification according to the first type target attribute and the text style information.

2. The method according to claim 1, It is characterized in that The filtering process of each of the text attributes to obtain a first type target attribute and a plurality of second type target attributes includes: Selecting a plurality of target text attributes from each of the text attributes, wherein the font size of each of the target text attributes is greater than or equal to a preset font size threshold; Determine the first type attribute with the largest number of uses among the target text attributes as the first type target attribute; The second type attributes of each of the target text attributes are divided to obtain a plurality of second type attribute sets; each of the second type attributes in each of the second type attribute sets has the same font size and the same font weight; The second type attributes in each second type attribute set are merged to obtain the second type target attributes corresponding to each second type attribute set; the second type target attributes corresponding to each second type attribute set include the font size, font weight, target line height and target character spacing of the second type attribute set; the target line height is the line height used most in the second type attribute set; the target character spacing is the character spacing used most in the second type attribute set.

3. The method according to claim 1, It is characterized in that The obtaining text style information through a preset large language model according to the preset prompt and each of the second-type target attributes includes: Obtaining a preset first prompt and a second prompt; the first prompt is used to indicate generating style information based on each of the second-type target attributes; the second prompt is used to indicate determining whether the style information meets the design specification, and if the style information does not meet the design specification, modifying the style information; Each of the second-type target attributes, the first prompt, and the second prompt is input into a preset large language model to obtain text style information that meets the design specifications.

4. The method according to claim 3, It is characterized in that The step of inputting each of the second-type target attributes, the first prompt, and the second prompt into a preset large language model to obtain text style information that meets the design specification includes: sorting each of the second-type target attributes according to the font size and / or font weight in each of the second-type target attributes; The sorted second-type target attributes, the first prompt, and the second prompt are input into a preset large language model to obtain text style information that meets the design specifications.

5. The method according to claim 1, It is characterized in that After generating the text specification according to the first type target attribute and the text style information, the method further includes: Creating a text style in the design drawing file according to the text specification; An illustration of the text specification is generated within the canvas of the design drawing file.

6. A text standard generating device, It is characterized in that include: An acquisition unit, used to acquire text attributes of each text layer in the design drawing file; The text attributes include first-type attributes and second-type attributes; the first-type attributes include fonts, and the second-type attributes include at least one of font size, font weight, line height, and character spacing; A first execution unit is used to screen and process each of the text attributes to obtain a first type target attribute and a plurality of second type target attributes; A first execution unit, configured to obtain text style information through a preset large language model according to a preset prompt and each of the second-type target attributes; A generating unit is used to generate a text specification according to the first type target attribute and the text style information.

7. The device according to claim 6, It is characterized in that The first execution unit includes: A selection subunit, configured to select a plurality of target text attributes from each of the text attributes, wherein the font size of each of the target text attributes is greater than or equal to a preset font size threshold; A determination subunit, configured to determine the first type of attribute with the largest number of uses among the target text attributes as the first type of target attribute; an attribute division subunit, configured to divide the second type attributes of each of the target text attributes to obtain a plurality of second type attribute sets; each of the second type attributes in each of the second type attribute sets has the same font size and the same font weight; The first execution sub-unit is used to merge the second type attributes in each second type attribute set to obtain the second type target attributes corresponding to each second type attribute set; the second type target attributes corresponding to each second type attribute set include the font size, font weight, target line height and target character spacing of the second type attribute set; the target line height is the line height with the largest number of uses in the second type attribute set; the target character spacing is the character spacing with the largest number of uses in the second type attribute set.

8. The device according to claim 6, It is characterized in that The second execution unit includes: an acquisition subunit, used for acquiring a preset first prompt and a second prompt; the first prompt is used for indicating generation of style information based on each second-type target attribute; the second prompt is used for indicating determination of whether the style information meets the design specification, and if the style information does not meet the design specification, the style information is modified; The second execution subunit is used to input each of the second-type target attributes, the first prompt and the second prompt into a preset large language model to obtain text style information that meets the design specifications.

9. A storage medium, It is characterized in that The storage medium includes storage instructions, wherein when the instructions are executed, the device where the storage medium is located is controlled to execute the text standard generation method according to any one of claims 1 to 5.

10. An electronic device, It is characterized in that The system comprises a memory and one or more instructions, wherein the one or more instructions are stored in the memory and configured to be executed by one or more processors to execute the text specification generating method according to any one of claims 1 to 5.