Jump to content

Issues With basic Job Allocation Algorithm

Go to solution Solved by Mira Yurizaki,
11 minutes ago, AliB2512 said:

so an integer of skill level, and an integer of current work load, and nested ifs? could create a basic system,?

I was thinking more like each person has a "work per time slice" value and the jobs have "work needed to be done" value, then iterate over time slices. Throw in a small randomizer on either end to keep things interesting as well. Choosing which person for the job though is another thing to consider, like if you want to prioritize shortest completion time or something.

I'm looking to create a basic algorithm that allocates jobs to workers based on skill level and workload. however, I'm stumped at where to start.

 

Background

Mobile phone repair store

Worker qualifications stored in text files

Algorithm is run as button click on the Add Repair Form (VB.net)

 

Requirements

Algorithm

Reads worker files sequentially, noting the current workload value,

finds the worker with at least amount of work

checks if he is qualified to do the task

If yes assigns job,

If no, checks the next worker

if 2 workers have the same amount of current jobs reads the first (sorted alphabetically) and runs checks

 

im struggling to even get psuedocode out for this. All Help appreciated

(Not asking for a full creation, just how to make this possible, pseudocode wise)

 

Basic attempt at flow chat may help

 

Flowchart.png

Link to comment
Share on other sites

Link to post
Share on other sites

Maybe instead of something vague like skill level, use a quantifiable value like say average time to complete a task with some randomness thrown in. You can come up with these numbers as long as it makes some measure of sense.

 

Or you can do the inverse and allocate time to complete the task and assign the appropriate person to the job, with a penalty if you have to choose someone who isn't as qualified. Or maybe a bonus to someone who's overqualified.

 

Either way, your algorithm is better suited if you have quantifiable values rather than a binary "is this person suitable for the job?"

Link to comment
Share on other sites

Link to post
Share on other sites

5 minutes ago, M.Yurizaki said:

Maybe instead of something vague like skill level, use a quantifiable value like say average time to complete a task with some randomness thrown in. You can come up with these numbers as long as it makes some measure of sense.

 

Or you can do the inverse and allocate time to complete the task and assign the appropriate person to the job, with a penalty if you have to choose someone who isn't as qualified. Or maybe a bonus to someone who's overqualified.

 

Either way, your algorithm is better suited if you have quantifiable values rather than a binary "is this person suitable for the job?"

 

so an integer of skill level, and an integer of current work load, and nested ifs? could create a basic system,?

 

Link to comment
Share on other sites

Link to post
Share on other sites

I think it would be simpler if given a certain task, you got a list of every worker qualified to do the task, and from that list, get the one with less current jobs.

I would assume task qualification is not a linear score, but a list of possible things to do, which may or may not be related to each other.

The best way to measure the quality of a piece of code is "Oh F*** "s per line

Link to comment
Share on other sites

Link to post
Share on other sites

11 minutes ago, AliB2512 said:

so an integer of skill level, and an integer of current work load, and nested ifs? could create a basic system,?

I was thinking more like each person has a "work per time slice" value and the jobs have "work needed to be done" value, then iterate over time slices. Throw in a small randomizer on either end to keep things interesting as well. Choosing which person for the job though is another thing to consider, like if you want to prioritize shortest completion time or something.

Link to comment
Share on other sites

Link to post
Share on other sites

3 minutes ago, M.Yurizaki said:

I was thinking more like each person has a "work per time slice" value and the jobs have "work needed to be done" value, then iterate over time slices. Throw in a small randomizer on either end to keep things interesting as well. Choosing which person for the job though is another thing to consider, like if you want to prioritize shortest completion time or something.

 

would it not be easier to deem skill on a linear scale, say 1-5 (1 being most skilled). and current jobs an integer. maybe multiplying them, using the output and comparing it to a Maximum number required to assign job', and whoever is the lowest in comparison, is assigned the job. (but i don't know how to handle for example skill level 2, and jobs 2, in comparison with skill level 4 but jobs 1) 

Link to comment
Share on other sites

Link to post
Share on other sites

2 minutes ago, AliB2512 said:

would it not be easier to deem skill on a linear scale, say 1-5 (1 being most skilled). and current jobs an integer. maybe multiplying them, using the output and comparing it to a Maximum number required to assign job', and whoever is the lowest in comparison, is assigned the job. (but i don't know how to handle for example skill level 2, and jobs 2, in comparison with skill level 4 but jobs 1) 

The thing with scheduling is you're not really scheduling based on skill level. You're scheduling based on time to completion. If you quantify how fast the workers can do vs. the amount of time the job can be done, you can avoid the situation you're having trouble with.

 

Skill level and job level are vague quantities at best. Some jobs are also not hard, but can take a long time to do. Like documenting software. That's not a hard thing to do (provided you have a working knowledge of what's going on), but it takes a long time to do. This is opposed to say finding a bug in the software and fixing it. Or implementing a new feature.

Link to comment
Share on other sites

Link to post
Share on other sites

1 minute ago, M.Yurizaki said:

The thing with scheduling is you're not really scheduling based on skill level. You're scheduling based on time to completion. If you quantify how fast the workers can do vs. the amount of time the job can be done, you can avoid the situation you're having trouble with.

 

Skill level and job level are vague quantities at best. Some jobs are also not hard, but can take a long time to do. Like documenting software. That's not a hard thing to do (provided you have a working knowledge of what's going on), but it takes a long time to do. This is opposed to say finding a bug in the software and fixing it. Or implementing a new feature.

 

yeah i can understand that, so a worker has a 'work per unit time' value, and the job is assigned a 'work value' thus giving worker a needs 4 hours to do job where as b need 3 hours ?how do the randomisers fall into place though?

Link to comment
Share on other sites

Link to post
Share on other sites

2 minutes ago, AliB2512 said:

how do the randomisers fall into place though?

It's see how your algorithm can handle a random workload, which is a better representation of applying this to real life.

 

Not applying a randomizer would be like saying "Look, Bubble sort is the best sorting method!" but your data sets were always in order.

Link to comment
Share on other sites

Link to post
Share on other sites

3 minutes ago, M.Yurizaki said:

It's see how your algorithm can handle a random workload, which is a better representation of applying this to real life.

 

Not applying a randomizer would be like saying "Look, Bubble sort is the best sorting method!" but your data sets were always in order.

 

you've lost me now, I understand how randomisers are used generally, just not in my context, where are they applied to, (sorry for being slow)

Link to comment
Share on other sites

Link to post
Share on other sites

7 minutes ago, AliB2512 said:

you've lost me now, I understand how randomisers are used generally, just not in my context, where are they applied to, (sorry for being slow)

You want to make an algorithm that tries to fit the best person for a job. You need a randomizer in order to characterize your algorithm (i.e., the Big O notation) in order to see how your algorithm does its job and to see if you can improve it.

Link to comment
Share on other sites

Link to post
Share on other sites

3 minutes ago, M.Yurizaki said:

You want to make an algorithm that tries to fit the best person for a job. You need a randomizer in order to characterize your algorithm (i.e., the Big O notation) in order to see how your algorithm does its job and to see if you can improve it.

 

I'm with you, thank you.

Link to comment
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×